[issue18359] pickle fail to handle some class with __new__

2013-07-04 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: This is expected, your class must say how this __new__ constructor can be called. http://docs.python.org/2/library/pickle.html#object.__getnewargs__ -- nosy: +amaury.forgeotdarc resolution: -> works for me status: open -> closed

[issue18359] pickle fail to handle some class with __new__

2013-07-04 Thread yoch
New submission from yoch: Hi, If some class objects have extra arguments in the __new__ constructor , pickle fail to serialize it. Here the output of provided test-case : Traceback (most recent call last): File "/home/yoch/bug.py", line 19, in y = pickle.load(fp) TypeError: __new__() m