diff options
author | Felix Crux <felixc@felixcrux.com> | 2013-08-12 21:39:51 (GMT) |
---|---|---|
committer | Felix Crux <felixc@felixcrux.com> | 2013-08-12 21:39:51 (GMT) |
commit | bc4b8ebc8bc2f30c98a80c3bf9894666f7f3d04c (patch) | |
tree | 29a5b31dce3a4ff6b4d18a9fef3f6b1294d98e8f | |
parent | 569a5faaea24277ef91202e8b16e8af7862033d2 (diff) | |
download | cpython-bc4b8ebc8bc2f30c98a80c3bf9894666f7f3d04c.zip cpython-bc4b8ebc8bc2f30c98a80c3bf9894666f7f3d04c.tar.gz cpython-bc4b8ebc8bc2f30c98a80c3bf9894666f7f3d04c.tar.bz2 |
Documenting that json.load may raise a ValueError.
Issue #18680: JSONDecoder should document that it raises a ValueError
for malformed data
-rw-r--r-- | Doc/library/json.rst | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Doc/library/json.rst b/Doc/library/json.rst index 433f948..f652039 100644 --- a/Doc/library/json.rst +++ b/Doc/library/json.rst @@ -328,6 +328,8 @@ Encoders and Decoders those with character codes in the 0-31 range, including ``'\t'`` (tab), ``'\n'``, ``'\r'`` and ``'\0'``. + If the data being deserialized is not a valid JSON document, a + :exc:`ValueError` will be raised. .. method:: decode(s) |