[issue3675] Python 2.6 can't read sets pickled with Python 3.0

Hagen Fürstenau report at bugs.python.org
Wed Aug 27 15:03:24 CEST 2008


Hagen Fürstenau <hfuerstenau at gmx.net> added the comment:

Well, this is obviously caused by renaming "__builtin__" to "builtins"
and the fact that set (as well as frozenset) doesn't have its own opcode
and therefore gets looked up in "builtins". The problem therefore
extends to all builtin objects without opcode special casing (e.g.
object, slice, property, ...) I'm afraid that means we have to pickle
"builtins" as "__builtin__" for backwards compatibility in protocols <= 2.

But aside from that, wouldn't it be more consistent to have opcodes for
set/frozenset in protocol 3?

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


More information about the Python-bugs-list mailing list