diff options
author | Łukasz Langa <lukasz@langa.pl> | 2012-12-31 02:41:54 (GMT) |
---|---|---|
committer | Łukasz Langa <lukasz@langa.pl> | 2012-12-31 02:41:54 (GMT) |
commit | 0dc5ab41f07a26deaebe46f593e572e221772aa2 (patch) | |
tree | 0e3eb3bb0e84366b91d501723ebf10097e10f946 /Doc | |
parent | 97eefc105ef13e1e6fa1fec39a914d83a751e7c7 (diff) | |
parent | c7ce3f7be5e72cf2253fc997bfdb6c80e27400f8 (diff) | |
download | cpython-0dc5ab41f07a26deaebe46f593e572e221772aa2.zip cpython-0dc5ab41f07a26deaebe46f593e572e221772aa2.tar.gz cpython-0dc5ab41f07a26deaebe46f593e572e221772aa2.tar.bz2 |
Merged `parser.clean()` fix (issue #16820) from 3.2.
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/library/configparser.rst | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Doc/library/configparser.rst b/Doc/library/configparser.rst index 958375b..0b8212c 100644 --- a/Doc/library/configparser.rst +++ b/Doc/library/configparser.rst @@ -389,7 +389,13 @@ However, there are a few differences that should be taken into account: the default value to be visible again. Trying to delete a default value causes a ``KeyError``. -* Trying to delete the ``DEFAULTSECT`` raises ``ValueError``. +* ``DEFAULTSECT`` cannot be removed from the parser: + + * trying to delete it raises ``ValueError``, + + * ``parser.clear()`` leaves it intact, + + * ``parser.popitem()`` never returns it. * ``parser.get(section, option, **kwargs)`` - the second argument is **not** a fallback value. Note however that the section-level ``get()`` methods are |