Message164825
| Author |
flub |
| Recipients |
flub, rj3d |
| Date |
2012年07月07日.11:46:46 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1341661606.92.0.655131853655.issue14290@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Hi, I think this is a usage error and if not you should try to provide a test case with both files for this.
Pickle needs to be able to import the module which contains the classes by the same name as the original module. That means pickling an instance of a class defined in a script will not work unless it is the same script which did the pickling. The object is probably pickled under the name __main__.YourClass and when you import it in another script it will be objectScript.YourClass, hence pickle is unable to find the class for the object you are trying to unpickle. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2012年07月07日 11:46:47 | flub | set | recipients:
+ flub, rj3d |
| 2012年07月07日 11:46:46 | flub | set | messageid: <1341661606.92.0.655131853655.issue14290@psf.upfronthosting.co.za> |
| 2012年07月07日 11:46:46 | flub | link | issue14290 messages |
| 2012年07月07日 11:46:46 | flub | create |
|