diff options
author | Vincent Michel <vxgmichel@gmail.com> | 2017-11-02 12:47:04 (GMT) |
---|---|---|
committer | Berker Peksag <berker.peksag@gmail.com> | 2017-11-02 12:47:04 (GMT) |
commit | e314853d57450b2b9523157eebd405289a795a0e (patch) | |
tree | c410df1fbf11b9ec522e915819c58f5f53cbd27a /Doc/library/configparser.rst | |
parent | a64ce973a3ad90e4f4a93c402e946c132f647a63 (diff) | |
download | cpython-e314853d57450b2b9523157eebd405289a795a0e.zip cpython-e314853d57450b2b9523157eebd405289a795a0e.tar.gz cpython-e314853d57450b2b9523157eebd405289a795a0e.tar.bz2 |
bpo-31307: Make ConfigParser.read() accept bytes objects (GH-3420)
Diffstat (limited to 'Doc/library/configparser.rst')
-rw-r--r-- | Doc/library/configparser.rst | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Doc/library/configparser.rst b/Doc/library/configparser.rst index acca647..dd82577 100644 --- a/Doc/library/configparser.rst +++ b/Doc/library/configparser.rst @@ -995,7 +995,8 @@ ConfigParser Objects Attempt to read and parse a list of filenames, returning a list of filenames which were successfully parsed. - If *filenames* is a string or :term:`path-like object`, it is treated as + If *filenames* is a string, a :class:`bytes` object or a + :term:`path-like object`, it is treated as a single filename. If a file named in *filenames* cannot be opened, that file will be ignored. This is designed so that you can specify a list of potential configuration file locations (for example, the current @@ -1022,6 +1023,9 @@ ConfigParser Objects .. versionadded:: 3.6.1 The *filenames* parameter accepts a :term:`path-like object`. + .. versionadded:: 3.7 + The *filenames* parameter accepts a :class:`bytes` object. + .. method:: read_file(f, source=None) |