Comment 2 for bug 516653

Revision history for this message
Marius Gedminas (mgedmin) wrote :

The Official Python Documentation states

   Note: For new-style classes, if __getstate__() returns a false value, the __setstate__() method will not be called.


It would appear that copy.deepcopy() is working as per spec, and it's just a happy accident that pickling BTrees.Length.Length() instances with the value of 0 works.

The fix should be trivial: add a class attribute 'value = 0' to BTrees.Length.Length.