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 sbt
Recipients barry, eli.bendersky, eric.smith, gvanrossum, ncoghlan, rhettinger, sbt
Date 2013-05-13.19:41:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In-reply-to <>
When pickling a class (or instance of a class) there is already a check 
that the invariant

     getattr(sys.modules[cls.__module__], cls.__name__) == cls


 >>> import pickle
 >>> class A: pass
 >>> A.__module__ = 'nonexistent'
 >>> pickle.dumps(A())
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
_pickle.PicklingError: Can't pickle <class 'nonexistent.A'>: import of 
module 'nonexistent' failed
Date User Action Args
2013-05-13 19:41:31sbtsetrecipients: + sbt, gvanrossum, barry, rhettinger, ncoghlan, eric.smith, eli.bendersky
2013-05-13 19:41:31sbtlinkissue17941 messages
2013-05-13 19:41:31sbtcreate