[issue4785] json.JSONDecoder() strict argument undocumented and potentially confusing

Tal Einat report at bugs.python.org
Fri Jun 4 17:10:13 CEST 2010


Tal Einat <taleinat at users.sourceforge.net> added the comment:

This goes down into _json.scanstring. Looking at the C code for scanstring_unicode, the strict parameter allow control characters inside strings: "if strict is zero then literal control characters are allowed". From the code itself (current py3k head, r81032), it seems this means any character <= 0x1f. See scanstring_unicode in http://svn.python.org/view/python/branches/py3k/Modules/_json.c?revision=81032&view=markup for details.

Documentation should be updated accordingly.

----------
nosy: +taleinat

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


More information about the Python-bugs-list mailing list