This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients SilentGhost, altvod, bob.ippolito, ezio.melotti, r.david.murray, rhettinger, serhiy.storchaka, terry.reedy
Date 2017-04-22.16:20:41
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
> I am surprised that dumping to a string and to a file give different answers.

This is a difference between Python and C implementations.

An iterable with fake __len__ looks breaking the invariants, but if a collection with overridden __bool__() is considered as more legitimate, the proposed patch fixes Python implementation of json for that case.
Date User Action Args
2017-04-22 16:20:42serhiy.storchakasetrecipients: + serhiy.storchaka, rhettinger, terry.reedy, bob.ippolito, ezio.melotti, r.david.murray, SilentGhost, altvod
2017-04-22 16:20:42serhiy.storchakasetmessageid: <>
2017-04-22 16:20:41serhiy.storchakalinkissue27613 messages
2017-04-22 16:20:41serhiy.storchakacreate