checkpointer 2.10.0__py3-none-any.whl → 2.10.1__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.
- checkpointer/checkpoint.py +1 -1
- checkpointer/object_hash.py +2 -0
- checkpointer/test_checkpointer.py +1 -3
- {checkpointer-2.10.0.dist-info → checkpointer-2.10.1.dist-info}/METADATA +2 -2
- {checkpointer-2.10.0.dist-info → checkpointer-2.10.1.dist-info}/RECORD +7 -7
- {checkpointer-2.10.0.dist-info → checkpointer-2.10.1.dist-info}/WHEEL +0 -0
- {checkpointer-2.10.0.dist-info → checkpointer-2.10.1.dist-info}/licenses/LICENSE +0 -0
checkpointer/checkpoint.py
CHANGED
@@ -116,7 +116,7 @@ class CachedFunction(Generic[Fn]):
|
|
116
116
|
return str(ObjectHash(hash_params, digest_size=16))
|
117
117
|
|
118
118
|
async def _resolve_awaitable(self, call_id: str, awaitable: Awaitable):
|
119
|
-
return
|
119
|
+
return self.storage.store(call_id, AwaitableValue(await awaitable)).value
|
120
120
|
|
121
121
|
def _call(self: CachedFunction[Callable[P, R]], args: tuple, kw: dict, rerun=False) -> R:
|
122
122
|
full_args = self.bound + args
|
checkpointer/object_hash.py
CHANGED
@@ -202,5 +202,7 @@ class ObjectHash:
|
|
202
202
|
return self.header("slots").update(slots)
|
203
203
|
if d := getattr(obj, "__dict__", {}):
|
204
204
|
return self.header("dict").update(d)
|
205
|
+
if isinstance(obj, Iterable):
|
206
|
+
return self._update_iterator(obj)
|
205
207
|
repr_str = re.sub(r"\s+(at\s+0x[0-9a-fA-F]+)(>)$", r"\2", repr(obj))
|
206
208
|
return self.header("repr").update(repr_str)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: checkpointer
|
3
|
-
Version: 2.10.
|
4
|
-
Summary:
|
3
|
+
Version: 2.10.1
|
4
|
+
Summary: checkpointer adds code-aware caching to Python functions, maintaining correctness and speeding up execution as your code changes.
|
5
5
|
Project-URL: Repository, https://github.com/Reddan/checkpointer.git
|
6
6
|
Author: Hampus Hallman
|
7
7
|
License: Copyright 2018-2025 Hampus Hallman
|
@@ -1,15 +1,15 @@
|
|
1
1
|
checkpointer/__init__.py,sha256=FBdEwdyQS2tc4eQMwrb9qsFgjPu9QOyLOqgDK2c1rAI,837
|
2
|
-
checkpointer/checkpoint.py,sha256=
|
2
|
+
checkpointer/checkpoint.py,sha256=yysni7CKzQ2XRX0nvEd34ktNjUcHVZ0CnKMaqQX-f_8,6827
|
3
3
|
checkpointer/fn_ident.py,sha256=hiPvm1lw9Aol6v-d5bjteWdg0VhrPQH4r1Wiow-Wzpo,4311
|
4
|
-
checkpointer/object_hash.py,sha256=
|
4
|
+
checkpointer/object_hash.py,sha256=kfyhFFxvcjwkexw5TKkAtCyWU3PZXgsWGJ5dsOaQXmY,7695
|
5
5
|
checkpointer/print_checkpoint.py,sha256=aJCeWMRJiIR3KpyPk_UOKTaD906kArGrmLGQ3LqcVgo,1369
|
6
|
-
checkpointer/test_checkpointer.py,sha256=
|
6
|
+
checkpointer/test_checkpointer.py,sha256=mvJu5EItLM95S6IdawgINVgqVCPBNx1bnMHJmwF_cwo,3731
|
7
7
|
checkpointer/utils.py,sha256=_zvbkno7221_4l_FbROJMRrs-enx8BRS4FGxn8et9Ns,2751
|
8
8
|
checkpointer/storages/__init__.py,sha256=en32nTUltpCSgz8RVGS_leIHC1Y1G89IqG1ZqAb6qUo,236
|
9
9
|
checkpointer/storages/memory_storage.py,sha256=Br30b1AyNOcNjjAaDui1mBjDKfhDbu--jV4WmJenzaE,1109
|
10
10
|
checkpointer/storages/pickle_storage.py,sha256=xS96q8TvwxH_TOZsiKmrMrhFwQKZCcaH7XOiECmuwl8,1628
|
11
11
|
checkpointer/storages/storage.py,sha256=dR84h-IN644XLGe7invSlzLuXlFlU8QIbsDZa1xdtPM,889
|
12
|
-
checkpointer-2.10.
|
13
|
-
checkpointer-2.10.
|
14
|
-
checkpointer-2.10.
|
15
|
-
checkpointer-2.10.
|
12
|
+
checkpointer-2.10.1.dist-info/METADATA,sha256=n7eiGDEoqRH-bEncwy27EM108HMwqVLHpDbYGY_PFZk,10908
|
13
|
+
checkpointer-2.10.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
14
|
+
checkpointer-2.10.1.dist-info/licenses/LICENSE,sha256=9xVsdtv_-uSyY9Xl9yujwAPm4-mjcCLeVy-ljwXEWbo,1059
|
15
|
+
checkpointer-2.10.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|