File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- Fix bug where FrozenList could not be pickled/unpickled.
1+ Fixed a bug where FrozenList could not be pickled/unpickled.
2+
3+ Pickling is a requirement for FrozenList to be able to be passed to multiprocessing Processes. Without this
4+ fix, users receive a TypeError upon attempting to pickle a FrozenList.
25-- by :user: `csm10495 `.
Original file line number Diff line number Diff line change 33import types
44from collections .abc import MutableSequence
55from functools import total_ordering
6- from typing import Any
76
87__version__ = "1.8.1.dev0"
98
@@ -105,7 +104,7 @@ def __reduce__(self):
105104 )
106105
107106
108- def _reconstruct_pyfrozenlist (items : list [Any ], frozen : bool ) -> "PyFrozenList" :
107+ def _reconstruct_pyfrozenlist (items : list [object ], frozen : bool ) -> "PyFrozenList" :
109108 """Helper function to reconstruct the pure Python FrozenList during unpickling.
110109 This function is needed since otherwise the class renaming confuses pickle."""
111110 fl = PyFrozenList (items )
You can’t perform that action at this time.
0 commit comments