pyzotero 1.6.7__py3-none-any.whl → 1.6.9__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- _version.py +2 -2
- pyzotero/filetransport.py +151 -0
- pyzotero/zotero.py +318 -394
- pyzotero/zotero_errors.py +17 -17
- {pyzotero-1.6.7.dist-info → pyzotero-1.6.9.dist-info}/METADATA +4 -2
- pyzotero-1.6.9.dist-info/RECORD +11 -0
- pyzotero-1.6.7.dist-info/RECORD +0 -10
- {pyzotero-1.6.7.dist-info → pyzotero-1.6.9.dist-info}/AUTHORS +0 -0
- {pyzotero-1.6.7.dist-info → pyzotero-1.6.9.dist-info}/LICENSE.md +0 -0
- {pyzotero-1.6.7.dist-info → pyzotero-1.6.9.dist-info}/WHEEL +0 -0
- {pyzotero-1.6.7.dist-info → pyzotero-1.6.9.dist-info}/top_level.txt +0 -0
pyzotero/zotero_errors.py
CHANGED
|
@@ -14,37 +14,37 @@ class PyZoteroError(Exception):
|
|
|
14
14
|
pass
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
class
|
|
17
|
+
class ParamNotPassedError(PyZoteroError):
|
|
18
18
|
"""Raised if a parameter which is required isn't passed"""
|
|
19
19
|
|
|
20
20
|
pass
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
class
|
|
23
|
+
class CallDoesNotExistError(PyZoteroError):
|
|
24
24
|
"""Raised if the specified API call doesn't exist"""
|
|
25
25
|
|
|
26
26
|
pass
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
class
|
|
29
|
+
class UnsupportedParamsError(PyZoteroError):
|
|
30
30
|
"""Raised when unsupported parameters are passed"""
|
|
31
31
|
|
|
32
32
|
pass
|
|
33
33
|
|
|
34
34
|
|
|
35
|
-
class
|
|
35
|
+
class UserNotAuthorisedError(PyZoteroError):
|
|
36
36
|
"""Raised when the user is not allowed to retrieve the resource"""
|
|
37
37
|
|
|
38
38
|
pass
|
|
39
39
|
|
|
40
40
|
|
|
41
|
-
class
|
|
41
|
+
class TooManyItemsError(PyZoteroError):
|
|
42
42
|
"""Raised when too many items are passed to a Write API method"""
|
|
43
43
|
|
|
44
44
|
pass
|
|
45
45
|
|
|
46
46
|
|
|
47
|
-
class
|
|
47
|
+
class MissingCredentialsError(PyZoteroError):
|
|
48
48
|
"""
|
|
49
49
|
Raised when an attempt is made to create a Zotero instance
|
|
50
50
|
without providing both the user ID and the user key
|
|
@@ -53,13 +53,13 @@ class MissingCredentials(PyZoteroError):
|
|
|
53
53
|
pass
|
|
54
54
|
|
|
55
55
|
|
|
56
|
-
class
|
|
56
|
+
class InvalidItemFieldsError(PyZoteroError):
|
|
57
57
|
"""Raised when an attempt is made to create/update items w/invalid fields"""
|
|
58
58
|
|
|
59
59
|
pass
|
|
60
60
|
|
|
61
61
|
|
|
62
|
-
class
|
|
62
|
+
class ResourceNotFoundError(PyZoteroError):
|
|
63
63
|
"""Raised when a resource (item, collection etc.) could not be found"""
|
|
64
64
|
|
|
65
65
|
pass
|
|
@@ -71,19 +71,19 @@ class HTTPError(PyZoteroError):
|
|
|
71
71
|
pass
|
|
72
72
|
|
|
73
73
|
|
|
74
|
-
class
|
|
74
|
+
class CouldNotReachURLError(PyZoteroError):
|
|
75
75
|
"""Raised when we can't reach a URL"""
|
|
76
76
|
|
|
77
77
|
pass
|
|
78
78
|
|
|
79
79
|
|
|
80
|
-
class
|
|
80
|
+
class ConflictError(PyZoteroError):
|
|
81
81
|
"""409 - Raised when the target library is locked"""
|
|
82
82
|
|
|
83
83
|
pass
|
|
84
84
|
|
|
85
85
|
|
|
86
|
-
class
|
|
86
|
+
class PreConditionFailedError(PyZoteroError):
|
|
87
87
|
"""
|
|
88
88
|
412 - Raised when the provided X-Zotero-Write-Token has already been
|
|
89
89
|
submitted
|
|
@@ -92,15 +92,15 @@ class PreConditionFailed(PyZoteroError):
|
|
|
92
92
|
pass
|
|
93
93
|
|
|
94
94
|
|
|
95
|
-
class
|
|
95
|
+
class RequestEntityTooLargeError(PyZoteroError):
|
|
96
96
|
"""
|
|
97
|
-
413
|
|
97
|
+
413 - The upload would exceed the storage quota of the library owner.
|
|
98
98
|
"""
|
|
99
99
|
|
|
100
100
|
pass
|
|
101
101
|
|
|
102
102
|
|
|
103
|
-
class
|
|
103
|
+
class PreConditionRequiredError(PyZoteroError):
|
|
104
104
|
"""
|
|
105
105
|
428 - Raised when If-Match or If-None-Match was not provided.
|
|
106
106
|
"""
|
|
@@ -108,7 +108,7 @@ class PreConditionRequired(PyZoteroError):
|
|
|
108
108
|
pass
|
|
109
109
|
|
|
110
110
|
|
|
111
|
-
class
|
|
111
|
+
class TooManyRequestsError(PyZoteroError):
|
|
112
112
|
"""
|
|
113
113
|
429 - Raised when there are too many unfinished uploads.
|
|
114
114
|
Try again after the number of seconds specified in the Retry-After header.
|
|
@@ -117,7 +117,7 @@ class TooManyRequests(PyZoteroError):
|
|
|
117
117
|
pass
|
|
118
118
|
|
|
119
119
|
|
|
120
|
-
class
|
|
120
|
+
class FileDoesNotExistError(PyZoteroError):
|
|
121
121
|
"""
|
|
122
122
|
Raised when a file path to be attached can't be opened (or doesn't exist)
|
|
123
123
|
"""
|
|
@@ -125,7 +125,7 @@ class FileDoesNotExist(PyZoteroError):
|
|
|
125
125
|
pass
|
|
126
126
|
|
|
127
127
|
|
|
128
|
-
class
|
|
128
|
+
class TooManyRetriesError(PyZoteroError):
|
|
129
129
|
"""
|
|
130
130
|
Raise after the backoff period for new requests exceeds 32s
|
|
131
131
|
"""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: pyzotero
|
|
3
|
-
Version: 1.6.
|
|
3
|
+
Version: 1.6.9
|
|
4
4
|
Summary: Python wrapper for the Zotero API
|
|
5
5
|
Author-email: Stephan Hügel <urschrei@gmail.com>
|
|
6
6
|
License: # Blue Oak Model License
|
|
@@ -41,6 +41,7 @@ License: # Blue Oak Model License
|
|
|
41
41
|
|
|
42
42
|
Project-URL: Repository, https://github.com/urschrei/pyzotero
|
|
43
43
|
Project-URL: Tracker, https://github.com/urschrei/pyzotero/issues
|
|
44
|
+
Project-URL: documentation, https://pyzotero.readthedocs.org
|
|
44
45
|
Keywords: Zotero,DH
|
|
45
46
|
Classifier: Programming Language :: Python
|
|
46
47
|
Classifier: Programming Language :: Python :: 3.9
|
|
@@ -63,12 +64,13 @@ Requires-Dist: feedparser>=6.0.11
|
|
|
63
64
|
Requires-Dist: pytz
|
|
64
65
|
Requires-Dist: bibtexparser
|
|
65
66
|
Requires-Dist: httpx>=0.28.1
|
|
66
|
-
Requires-Dist: httpx-file>=0.2.0
|
|
67
67
|
Provides-Extra: test
|
|
68
68
|
Requires-Dist: pytest>=7.4.2; extra == "test"
|
|
69
69
|
Requires-Dist: httpretty; extra == "test"
|
|
70
70
|
Requires-Dist: python-dateutil; extra == "test"
|
|
71
71
|
Requires-Dist: ipython; extra == "test"
|
|
72
|
+
Requires-Dist: pytest-asyncio; extra == "test"
|
|
73
|
+
Requires-Dist: pytest-cov>=6.0.0; extra == "test"
|
|
72
74
|
|
|
73
75
|
[](https://pypi.python.org/pypi/Pyzotero/) [](http://pyzotero.readthedocs.org/en/latest/?badge=latest) [](https://pypi.python.org/pypi/Pyzotero) [](https://anaconda.org/conda-forge/pyzotero) [](https://pepy.tech/project/pyzotero)
|
|
74
76
|
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
_version.py,sha256=H4tpGbuK5q1tqtuUh1Nr2Buwsz8VycRrcpqeBxyquBg,411
|
|
2
|
+
pyzotero/__init__.py,sha256=5QI4Jou9L-YJAf_oN9TgRXVKgt_Unc39oADo2Ch8bLI,243
|
|
3
|
+
pyzotero/filetransport.py,sha256=umLik1LLmrpgaNmyjvtBoqqcaMgIq79PYsTvN5vG-gY,5530
|
|
4
|
+
pyzotero/zotero.py,sha256=Y9XmvqzISwYyKQldVveV05bOup5-dt7TukaEwsqPp38,76076
|
|
5
|
+
pyzotero/zotero_errors.py,sha256=6obx9-pBO0z1bxt33vuzDluELvA5kSLCsfc-uGc3KNw,2660
|
|
6
|
+
pyzotero-1.6.9.dist-info/AUTHORS,sha256=ZMicxg7lRScOYbxzMPznlzMbmrFIUIHwg-NvljEMbRQ,110
|
|
7
|
+
pyzotero-1.6.9.dist-info/LICENSE.md,sha256=bhy1CPMj1zWffD9YifFmSeBzPylsrhb1qP8OCEx5Etw,1550
|
|
8
|
+
pyzotero-1.6.9.dist-info/METADATA,sha256=cUNZYdjomh6Cb-8hbPB-yuyA151gjn4DLO_5FI0yQLQ,7448
|
|
9
|
+
pyzotero-1.6.9.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
|
10
|
+
pyzotero-1.6.9.dist-info/top_level.txt,sha256=BOPNkPk5VtNDCy_li7Xftx6k0zG8STGxh-KgckcxLEw,18
|
|
11
|
+
pyzotero-1.6.9.dist-info/RECORD,,
|
pyzotero-1.6.7.dist-info/RECORD
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
_version.py,sha256=UBH9kvxesdE0svvcKwHfK8rz5bJUzNXPBHo7APqVEfk,411
|
|
2
|
-
pyzotero/__init__.py,sha256=5QI4Jou9L-YJAf_oN9TgRXVKgt_Unc39oADo2Ch8bLI,243
|
|
3
|
-
pyzotero/zotero.py,sha256=alCXV2WAagw6EL8nAJ4y9iZ3FFIE3-wJeCMYRbh1XTU,77343
|
|
4
|
-
pyzotero/zotero_errors.py,sha256=UPhAmf2K05cnoeIl2wjufWQedepg7vBKb-ShU0TdlL4,2582
|
|
5
|
-
pyzotero-1.6.7.dist-info/AUTHORS,sha256=ZMicxg7lRScOYbxzMPznlzMbmrFIUIHwg-NvljEMbRQ,110
|
|
6
|
-
pyzotero-1.6.7.dist-info/LICENSE.md,sha256=bhy1CPMj1zWffD9YifFmSeBzPylsrhb1qP8OCEx5Etw,1550
|
|
7
|
-
pyzotero-1.6.7.dist-info/METADATA,sha256=dR-omf9ajswDWyICEkqL_FCs_Y08c2G-TLO3zYAUkHE,7323
|
|
8
|
-
pyzotero-1.6.7.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
|
9
|
-
pyzotero-1.6.7.dist-info/top_level.txt,sha256=BOPNkPk5VtNDCy_li7Xftx6k0zG8STGxh-KgckcxLEw,18
|
|
10
|
-
pyzotero-1.6.7.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|