[Numpy-discussion] Fwd: Pull request #3188 - Void scalar pickling behavior.

Alex Ford fordas@uw....
Sat Apr 6 14:03:54 CDT 2013


Hello,

Do any core developers or uses have guidance on how to resolve PR #3188 (
https://github.com/numpy/numpy/pull/3188) in relation to the pickling
behavior of array scalar objects?

To summarize, pickling array scalars with object fields, which are produced
when indexing record arrays with object fields, stores the object address
instead of pickling the referenced object. This behavior, obviously,
results in invalid references on unpickling.

Two current options are to:
A) Raise an exception on pickling scalars with object fields.
B) Transparently convert scalars to zero-rank arrays on pickling, which
pickle properly.

Unless there are objections or opinions on potential solutions, I am
inclined to implement A.

Thanks,
Alex Ford
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20130406/8d918662/attachment.html 


More information about the NumPy-Discussion mailing list