Re: Help: pickle module unable to load "rb" mode files in linux

2013-04-07 Thread 88888 Dihedral
Surya Kasturi於 2013年4月2日星期二UTC+8下午10時54分25秒寫道: > Hi, hope you can help me on it.. > > > > with open(pickle_f, 'r') as fhand: >         obj = pickle.load(fhand) > > > > > This works on linux but not in windows until  I use "rb" mode while creating > file object. Surprisingly, the "rb" mode i

Re: Help: pickle module unable to load "rb" mode files in linux

2013-04-07 Thread Peter Otten
Surya Kasturi wrote: > I am attaching the file which has to be read.. please take a look into it. > The actual source code can be observed at > https://github.com/scipy/SciPyCentral/blob/master/scipy_central/rest_comments/views.py#L235 > > > when we use "rb" mode in windows, its working. but it

Re: Help: pickle module unable to load "rb" mode files in linux

2013-04-07 Thread Surya Kasturi
I am attaching the file which has to be read.. please take a look into it. The actual source code can be observed at https://github.com/scipy/SciPyCentral/blob/master/scipy_central/rest_comments/views.py#L235 when we use "rb" mode in windows, its working. but its not working in linux system (part

Re: Help: pickle module unable to load "rb" mode files in linux

2013-04-02 Thread Peter Otten
Surya Kasturi wrote: > Hi, hope you can help me on it.. > > with open(pickle_f, 'r') as fhand: > obj = pickle.load(fhand) > > > This works on linux but not in windows until I use "rb" mode while > creating file object. Surprisingly, the "rb" mode is not working on > Linux.. raising EOF

Help: pickle module unable to load "rb" mode files in linux

2013-04-02 Thread Surya Kasturi
Hi, hope you can help me on it.. with open(pickle_f, 'r') as fhand: obj = pickle.load(fhand) This works on linux but not in windows until I use "rb" mode while creating file object. Surprisingly, the "rb" mode is not working on Linux.. raising EOFError. Why is this happening? -- http: