Message249560
| Author |
serhiy.storchaka |
| Recipients |
Jakob.Bowyer, Ramchandra Apte, alexandre.vassalotti, r.david.murray, rhettinger, serhiy.storchaka, terry.reedy |
| Date |
2015年09月02日.18:59:18 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1441220358.68.0.979358244716.issue14350@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Actually the tp_new field of list iterator class is NULL. Unpickler raises other error in such case (see issue24900 for example).
UnpicklingError: NEWOBJ class argument has NULL tp_new
Backported to 2.7 the part of the patch for issue22995 fixes this issue.
>>> copy.copy(iter([]))
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/serhiy/py/cpython-2.7/Lib/copy.py", line 88, in copy
rv = reductor(2)
TypeError: can't pickle listiterator objects |
|