]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.9] bpo-20923 : [doc] Explain ConfigParser 'valid section name' and .SECTCRE ...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 22 Feb 2022 18:43:55 +0000 (10:43 -0800)
committerGitHub <noreply@github.com>
Tue, 22 Feb 2022 18:43:55 +0000 (10:43 -0800)
(cherry picked from commit bba8008f99d615a02984422a3825082bb5621f5a)

Co-authored-by: vidhya <96202776+Vidhyavinu@users.noreply.github.com>
Automerge-Triggered-By: GH:iritkatriel
Doc/library/configparser.rst

index 60d33f59276f9485534e39b38e95e60afbcac204..e5c78246881f1926908e1b5f4ed8bf8da94e32bc 100644 (file)
@@ -243,6 +243,9 @@ out.  Values can also span multiple lines, as long as they are indented deeper
 than the first line of the value.  Depending on the parser's mode, blank lines
 may be treated as parts of multiline values or ignored.
 
+By default,  a valid section name can be any string that does not contain '\\n' or ']'.
+To change this, see :attr:`ConfigParser.SECTCRE`.
+
 Configuration files may include comments, prefixed by specific
 characters (``#`` and ``;`` by default [1]_).  Comments may appear on
 their own on an otherwise empty line, possibly indented. [1]_