windows to linux pickled objects?

Fernando Pérez fperez528 at yahoo.com
Mon Nov 26 23:44:04 CET 2001


Stephen Boulet wrote:

> I pickled a list in windows but couldn't open it in linux without
> first running the handy dos2unix program on it.
> 
...
> On linux at home I rejoined the parts with cat and gunzipped it. It
> went from 1.6 MB to 8.2 MB. Those pickles can get big.
> 
> -- Stephen

I suspect the solution is just to pickle in binary. Otherwise you run 
into the usual mess of 'what's a newline' between unix and windows. 
Besides, if your pickles are that big binary is the way to go anyways.

cheers,

f



More information about the Python-list mailing list