omnata-plugin-runtime 0.5.0a112__py3-none-any.whl → 0.5.1a114__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- omnata_plugin_runtime/rate_limiting.py +5 -4
- {omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/METADATA +6 -1
- {omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/RECORD +5 -5
- {omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/LICENSE +0 -0
- {omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/WHEEL +0 -0
@@ -178,10 +178,9 @@ class RateLimitState(SubscriptableBaseModel):
|
|
178
178
|
[],
|
179
179
|
description="A list of timestamps where previous requests have been made, used to calculate the next request time",
|
180
180
|
)
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
)
|
181
|
+
# can't set this as a class variable because it's not serializable
|
182
|
+
# TODO: probably shouldn't mix models with functionality like this
|
183
|
+
_request_timestamps_lock: Optional[threading.Lock] = None
|
185
184
|
|
186
185
|
@field_serializer('wait_until',when_used='always')
|
187
186
|
def serialize_wait_until(self, value:Optional[datetime.datetime]) -> Optional[int]:
|
@@ -253,6 +252,8 @@ class RateLimitState(SubscriptableBaseModel):
|
|
253
252
|
You only need to use this if your HTTP requests are not automatically being
|
254
253
|
registered, which happens if http.client.HTTPConnection is not being used.
|
255
254
|
"""
|
255
|
+
if self._request_timestamps_lock is None:
|
256
|
+
self._request_timestamps_lock = threading.Lock()
|
256
257
|
with self._request_timestamps_lock:
|
257
258
|
append_time = datetime.datetime.now(datetime.timezone.utc)
|
258
259
|
if self.previous_request_timestamps is None:
|
{omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/METADATA
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: omnata-plugin-runtime
|
3
|
-
Version: 0.5.
|
3
|
+
Version: 0.5.1a114
|
4
4
|
Summary: Classes and common runtime components for building and running Omnata Plugins
|
5
5
|
Author: James Weakley
|
6
6
|
Author-email: james.weakley@omnata.com
|
@@ -9,8 +9,11 @@ Classifier: Programming Language :: Python :: 3
|
|
9
9
|
Classifier: Programming Language :: Python :: 3.8
|
10
10
|
Classifier: Programming Language :: Python :: 3.9
|
11
11
|
Classifier: Programming Language :: Python :: 3.10
|
12
|
+
Requires-Dist: annotated-types (<=0.6.0)
|
12
13
|
Requires-Dist: certifi (<=2024.7.4)
|
13
14
|
Requires-Dist: charset-normalizer (<=2.0.4)
|
15
|
+
Requires-Dist: cryptography (<=42.0.5)
|
16
|
+
Requires-Dist: filelock (<=3.13.1)
|
14
17
|
Requires-Dist: idna (<=3.7)
|
15
18
|
Requires-Dist: jinja2 (>=3.1.2,<=3.1.4)
|
16
19
|
Requires-Dist: markupsafe (<=2.1.3)
|
@@ -18,7 +21,9 @@ Requires-Dist: numpy (<=1.26.4)
|
|
18
21
|
Requires-Dist: packaging (<=24.1)
|
19
22
|
Requires-Dist: pandas (<=2.2.2)
|
20
23
|
Requires-Dist: platformdirs (<=3.10.0)
|
24
|
+
Requires-Dist: pycparser (<=2.21)
|
21
25
|
Requires-Dist: pydantic (>=2,<=2.5.3)
|
26
|
+
Requires-Dist: pydantic-core (<=2.14.6)
|
22
27
|
Requires-Dist: pyjwt (<=2.8.0)
|
23
28
|
Requires-Dist: pyopenssl (<=24.0.0)
|
24
29
|
Requires-Dist: pytz (<=2024.1)
|
{omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/RECORD
RENAMED
@@ -5,8 +5,8 @@ omnata_plugin_runtime/forms.py,sha256=hV6jVaizex20Pb9NxPx11TBPK-Yy8pREAnTtCxHo4Q
|
|
5
5
|
omnata_plugin_runtime/logging.py,sha256=bn7eKoNWvtuyTk7RTwBS9UARMtqkiICtgMtzq3KA2V0,3272
|
6
6
|
omnata_plugin_runtime/omnata_plugin.py,sha256=zIk8dS5m4pXsVy_2im-Cd-t1uQV9hf1seosb1T2jGGs,110880
|
7
7
|
omnata_plugin_runtime/plugin_entrypoints.py,sha256=xlPTI25N5G3l0bRFSkga98TIHM44NRaN2g7T5jSsqX0,29181
|
8
|
-
omnata_plugin_runtime/rate_limiting.py,sha256=
|
9
|
-
omnata_plugin_runtime-0.5.
|
10
|
-
omnata_plugin_runtime-0.5.
|
11
|
-
omnata_plugin_runtime-0.5.
|
12
|
-
omnata_plugin_runtime-0.5.
|
8
|
+
omnata_plugin_runtime/rate_limiting.py,sha256=DVQ_bc-mVLBkrU1PTns1MWXhHiLpSB5HkWCcdePtJ2A,25611
|
9
|
+
omnata_plugin_runtime-0.5.1a114.dist-info/LICENSE,sha256=IMF9i4xIpgCADf0U-V1cuf9HBmqWQd3qtI3FSuyW4zE,26526
|
10
|
+
omnata_plugin_runtime-0.5.1a114.dist-info/METADATA,sha256=yf8uYGHInQ_N6bUEZyTgvvVodiYL0mxHtj3jy94BIhU,1888
|
11
|
+
omnata_plugin_runtime-0.5.1a114.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
12
|
+
omnata_plugin_runtime-0.5.1a114.dist-info/RECORD,,
|
{omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/LICENSE
RENAMED
File without changes
|
{omnata_plugin_runtime-0.5.0a112.dist-info → omnata_plugin_runtime-0.5.1a114.dist-info}/WHEEL
RENAMED
File without changes
|