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.

Author rj3d
Recipients rj3d
Date 2012-03-13.19:40:40
SpamBayes Score 1.2705054e-10
Marked as misclassified No
Message-id <1331667642.01.0.680129740358.issue14290@psf.upfronthosting.co.za>
In-reply-to
Content
I implemented a data-structure as an object in a script, let's call it objectScript.py. I'm using this data-structure in other scripts like so:

from objectScript import data-structure

Populating this data-structure requires quite a bit of time, so when I'm done with it, I like to pickle it. However, if I try to load it from the pickled file, I get the following error:

ImportError: No module named objectScript

However, if I replace my 'from objectScript import data-structure' statement with the actual data-structure class definition from the objectScript.py file when I am pickling the object but then revert to the import statement when I am unpickling the object, everything works fine.
History
Date User Action Args
2012-03-13 19:40:42rj3dsetrecipients: + rj3d
2012-03-13 19:40:42rj3dsetmessageid: <1331667642.01.0.680129740358.issue14290@psf.upfronthosting.co.za>
2012-03-13 19:40:40rj3dlinkissue14290 messages
2012-03-13 19:40:40rj3dcreate