Skip to content

Commit

Permalink
fix: make _getstate working on Python 3.11
Browse files Browse the repository at this point in the history
  • Loading branch information
marcofavorito committed Jun 6, 2023
1 parent 532b3e0 commit 5530ceb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pddl/helpers/cache_hash.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ def _getstate(fn):
@wraps(fn)
def __getstate__(self):
d = fn(self)
if d is None:
return None
# assuming d is a dictionary
d.pop("__hash", None)
return d

Expand Down

0 comments on commit 5530ceb

Please sign in to comment.