This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: pickle/cPickle EOL incompatibility
Type: Stage:
Components: Extension Modules Versions: Python 2.2
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: gvanrossum Nosy List: gvanrossum, sleeper
Priority: normal Keywords:

Created on 2002-01-10 14:21 by sleeper, last changed 2022-04-10 16:04 by admin. This issue is now closed.

Messages (2)
msg8695 - (view) Author: James Weatherall (sleeper) Date: 2002-01-10 14:21
There seems to be a problem loading pickled data 
written under Windows (EOL = \r\n) from within Linux 
(EOL = \n).  The problem manifests as being unable to 
import the required module.  Reading Linux pickle data 
under Windows works fine.

e.g. a pickle file containing objects from module Foo 
will fail to import Foo, because it *actually* tries 
to import "Foo\r", and obviously can't.

(Seems unlikely that noone else has noticed this, so 
perhaps I'm just being spectacularly dumb.)
msg8696 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2002-01-10 14:41
Logged In: YES 
user_id=6380

On Windows, you have to open files containing pickles in
binary mode ("rb", "wb").

Closing as Invalid.
History
Date User Action Args
2022-04-10 16:04:51adminsetgithub: 35897
2002-01-10 14:21:31sleepercreate