Array of objects lost in unpickling
Christian Heimes
lists at cheimes.de
Sun Sep 13 11:09:29 EDT 2009
Bahadir wrote:
> Also there are no errors printed out.
>
> Any idea why the array of instances are lost?
>
The pickle protocol doesn't pickle class attributes by default, only
instance variables. You list called 'array' is a class variable -- it's
bound to the class not your instance.
By the way it's called a list in Python, not array.
Christian
More information about the Python-list
mailing list