Author njs
Recipients Amit Feller, Eli_B, njs, pitrou, r.david.murray, serhiy.storchaka, thomas-arildsen
Date 2016-01-04.11:20:23
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1451906423.95.0.535709328822.issue24313@psf.upfronthosting.co.za>
In-reply-to
Content
Nothing's changed in python 2.7. Basically: (a) no numpy ints have ever serialized in py3. (b) in py2, either np.int32 *xor* np.int64 will serialize correctly, and which one it is depends on sizeof(long) in the C compiler used to build Python. (This follows from the fact that in py2, the Python 'int' type is always the same size as C 'long'.)

So the end result is: on OS X and Linux, 32-bit Pythons can JSON-serialize np.int32 objects, and 64-bit Pythons can JSON-serialize np.int64 objects, because 64-bit OS X and Linux is ILP64. On Windows, both 32- and 64-bit Pythons can JSON-serialize np.int32 objects, and can't serialize np.int64 objects, because 64-bit Windows is LLP64.
History
Date User Action Args
2016-01-04 11:20:23njssetrecipients: + njs, pitrou, r.david.murray, Eli_B, serhiy.storchaka, thomas-arildsen, Amit Feller
2016-01-04 11:20:23njssetmessageid: <1451906423.95.0.535709328822.issue24313@psf.upfronthosting.co.za>
2016-01-04 11:20:23njslinkissue24313 messages
2016-01-04 11:20:23njscreate