Message255280
__reduce__() and __setstate__() methods of itertools.accumulate() look correct. The problem is not in itertools.accumulate(), but in the copy module. It uses the same __reduce__ protocol as pickle, but in different way. In the pickle module (in both Python and C implementations) state value is ignored only if it is None. In the copy module any state with boolean value is False is ignored.
Proposed patch fixes the copy module. |
|
Date |
User |
Action |
Args |
2015-11-24 16:37:10 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, arigo, kristjan.jonsson, alexandre.vassalotti |
2015-11-24 16:37:09 | serhiy.storchaka | set | messageid: <1448383029.96.0.715722589184.issue25718@psf.upfronthosting.co.za> |
2015-11-24 16:37:09 | serhiy.storchaka | link | issue25718 messages |
2015-11-24 16:37:09 | serhiy.storchaka | create | |
|