Issue1291509
Created on 2005-09-15.00:57:21 by anonymous, last changed 2007-08-14.16:24:39 by cgroves.
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2005-09-15 00:57:21 | anonymous | create | |
Created on 2005-09-15.00:57:21 by anonymous, last changed 2007-08-14.16:24:39 by cgroves.
| Messages | |||
|---|---|---|---|
| msg1036 (view) | Author: Nobody/Anonymous (nobody) | Date: 2005-09-15.00:57:21 | |
I get a ClassCastException when the unpickler tried to call __setstate__. It works fine with CPython (both pickle and cPickle) and it works fie when I use pickle in jython. But it fails using cPickle in Jython. |
|||
| msg1037 (view) | Author: Deleted User leouserz (leouserz) | Date: 2007-01-15.16:43:57 | |
Is there a test case for this?
import cPickle
a = cPickle()
i = 1000
x = a.dumps(i)
print x
v = a.loads(x)
print v
this works ok. Also a class that defines __setstate__ works ok from what I can see:
>>> class f:
... def __setstate__(self, r):
... print r
...
>>> g = f()
>>> x = a.dumps(g)
>>> x
'(i__main__\nf\np1\n(dp2\nb.'
>>> x2 = a.loads(x)
{}
>>> x2
<__main__.f instance 1>
>>>
|
|||
| msg1038 (view) | Author: Charlie Groves (cgroves) | Date: 2007-01-25.19:34:30 | |
I was mainly leaving this open because test_cpickle still fails. Moving this out of 2.2beta since we're not focusing on library compatibility as much. |
|||
| msg1039 (view) | Author: rajesh battala (rajesh_battala) | Date: 2007-08-09.06:25:21 | |
i am looking at this bug |
|||
| msg1040 (view) | Author: Charlie Groves (cgroves) | Date: 2007-08-14.16:24:39 | |
We already have other cPickling bugs, so leaving this open as a reminder of cPickling problems is no longer necessary and the actual __setstate__ problem disappeared. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2005-09-15 00:57:21 | anonymous | create | |
Supported by Python Software Foundation,
Powered by Roundup