Skip to content

Commit

Permalink
Fix compatibility with older Python.
Browse files Browse the repository at this point in the history
  • Loading branch information
tonyandrewmeyer committed Jul 8, 2024
1 parent 1615fad commit a47ddc7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scenario/state.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def __new__(cls, *args, **kwargs):
def __reduce__(self):
# The default __reduce__ doesn't understand that some arguments have
# to be passed as keywords, so using the copy module fails.
attrs = cast(Dict[str, Any], self.__getstate__())
attrs = cast(Dict[str, Any], super().__reduce__()[2])
return (lambda: self.__class__(**attrs), ())

return _MaxPositionalArgs
Expand Down

0 comments on commit a47ddc7

Please sign in to comment.