From: Steven D'Aprano wrote:
<>
Right, thanks.
<>
I want to include this info in my presentation because it shows how
data structures can be externalized.
<>
Still though, that is important.
< Sarcasm aside, what else could "import pickle" mean other than import
> the pickle module?>>
I wa
Cranky Frankie wrote:
From: Peter Otten <__pete...@web.de> wrote:
snip
<>
Thanks Peter, that was it. I was treating pickle like standard file
i/o when it's not that at all.
I don't understand what you mean by this.
Pickle does standard file I/O in the same way that opening a JPEG in an
image
Cranky Frankie wrote:
I'm reading in a pickled file. The program works but I'm having
trouble sensing end of file. Here's the program:
[...]
Traceback (most recent call last):
File "D:\MyDocs\Python\pickle_in.py", line 21, in
read_file = pickle.load(pickle_file)# read the next re
On Wed, Nov 23, 2011 at 12:03 PM, Cranky Frankie
wrote:
> [...]
> The reason why I'm "pickling" is I'm trying to include information on
> Python data structures in the presentaton I'm preparing. [...]
>
In your context why not just use modules?
# data.py
Qb_dict = {"Montana": ["Joe", "Montana"
From: Peter Otten <__pete...@web.de> wrote:
snip
<>
Thanks Peter, that was it. I was treating pickle like standard file
i/o when it's not that at all.
The reason why I'm "pickling" is I'm trying to include information on
Python data structures in the presentaton I'm preparing.
Here are the two p
Cranky Frankie wrote:
> I'm reading in a pickled file. The program works but I'm having
> trouble sensing end of file. Here's the program:
>
> #
> # pickle_in.py
> # program to read in a pickled file
> #
> # Frank L. Palmeri
> #
>
> import pickle # import the pi
I'm reading in a pickled file. The program works but I'm having
trouble sensing end of file. Here's the program:
#
# pickle_in.py
# program to read in a pickled file
#
# Frank L. Palmeri
#
import pickle # import the pickle module
pickle_file = open("d:/Work/pickl