[issue17941] namedtuple should support fully qualified name for more portable pickling

Guido van Rossum report at bugs.python.org
Mon May 13 21:03:13 CEST 2013


Guido van Rossum added the comment:

I'd like to propose one slight tweak to the patch.  (Also to enum.py.)

If no module name was passed and _getframe() fails, can you set the __module__ attribute to something that will cause pickling the object to fail?  That would be much better than letting it pickle but then being unable to unpickle it.

(TBH I'm not sure how this should be accomplished, and if it can't, forget that I said it.  But it would be nice.)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue17941>
_______________________________________


More information about the Python-bugs-list mailing list