[issue4176] segfault with pickle if 4th or 5th item of tuple returned by __reduce__ is not an iterator

Alexandre Vassalotti report at bugs.python.org
Fri Oct 31 22:05:54 CET 2008


Alexandre Vassalotti <alexandre at peadrop.com> added the comment:

Amaury Forgeot d'Arc wrote:
> Regarding the consistency between python and C, I don't think it is 
> necessary to be so strict. If the python version can allow a weaker 
> version of the "iterator" concept, let be it.

I guess you're right. However, my only fear is that people will write
code for pickle.py and then, when they run it on _pickle, their code
will fail due to the stricter requirements. In addition, I think having
the same requirements make it easier to write tests for both
implementations.

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4176>
_______________________________________


More information about the Python-bugs-list mailing list