[PYTHON MATRIX-SIG] pickle error on Win95
Groma Geza
GROMA@everx.szbk.u-szeged.hu
Wed, 20 Mar 1996 11:49:19 MET
> Your hex dump looks right to me, so I'd guess that the error is
> something else.
Meanwhile I fround that pickle.load() fails if the value of any
element of an integer array is 13 (CR!?). This is demonstrated in the
following example:
---------------------------------------------------
>>> import pickle
>>> from Numeric import *
>>> def CreateBug(m):
... fp=open("test","w")
... pickle.dump(m,fp)
... fp.close()
... fp=open("test","r")
... y=pickle.load(fp)
... print y
...
>>> CreateBug(array([12,14,15]))
12 14 15
>>> CreateBug(array([12,13,14]))
Traceback (innermost last):
File "<stdin>", line 1, in ?
File "<stdin>", line 6, in CreateBug
File "c:\Python\Lib\pickle.py", line 533, in load
return Unpickler(file).load()
File "c:\Python\Lib\pickle.py", line 375, in load
self.dispatch[key](self)
File "c:\Python\Lib\pickle.py", line 387, in load_eof
raise EOFError
EOFError
>>>
----------------------------------------------------------------------
If you have any idea how to fix this error, I am eager to check it on
my system.
> I'm surprised that v0.35 compiled on Win95 without any compilation
> errors. I haven't yet implemented any of the patches that others have
> told me are needed to get things to compile under windows. Did you
> have to make any changes to the code?
Absolutely no change was necessery for Symantec C.
Geza I. Groma
Institute of Biophysics
Biological Research Centre of Hungarian Academy of Sciences
Szeged, Hungary
=================
MATRIX-SIG - SIG on Matrix Math for Python
send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
=================