Skip to content

Commit fd1e3fe

Browse files
[3.13] gh-141757: Comply with pickle protocol in test_reduce_5tuple (GH-141759) (GH-141783)
The 5th element of the __reduce__ tuple should be an iterator. (cherry picked from commit 41b9ad5) Co-authored-by: Arseny Boykov <36469655+Bobronium@users.noreply.github.com>
1 parent 2ebe685 commit fd1e3fe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/test/test_copy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -666,7 +666,7 @@ def __eq__(self, other):
666666
def test_reduce_5tuple(self):
667667
class C(dict):
668668
def __reduce__(self):
669-
return (C, (), self.__dict__, None, self.items())
669+
return (C, (), self.__dict__, None, iter(self.items()))
670670
def __eq__(self, other):
671671
return (dict(self) == dict(other) and
672672
self.__dict__ == other.__dict__)

0 commit comments

Comments
 (0)