diff options
author | Zackery Spytz <zspytz@gmail.com> | 2018-09-29 16:15:55 (GMT) |
---|---|---|
committer | Brian Curtin <brian@python.org> | 2018-09-29 16:15:55 (GMT) |
commit | e45473e3ca31e5b78dc85cab575f5bb60d5b7f8f (patch) | |
tree | 356cfeb6de1032846ea00e229f861de7ee8fb34e /Lib/configparser.py | |
parent | eef059657d6b10babdb4831e1148d60cc644ee9a (diff) | |
download | cpython-e45473e3ca31e5b78dc85cab575f5bb60d5b7f8f.zip cpython-e45473e3ca31e5b78dc85cab575f5bb60d5b7f8f.tar.gz cpython-e45473e3ca31e5b78dc85cab575f5bb60d5b7f8f.tar.bz2 |
bpo-27351: Fix ConfigParser.read() documentation and docstring (GH-8123)
Switch "list" with "iterable" to match with the implementation.
Diffstat (limited to 'Lib/configparser.py')
-rw-r--r-- | Lib/configparser.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/configparser.py b/Lib/configparser.py index 4a16101..79a9910 100644 --- a/Lib/configparser.py +++ b/Lib/configparser.py @@ -80,7 +80,7 @@ ConfigParser -- responsible for parsing a list of Return list of configuration options for the named section. read(filenames, encoding=None) - Read and parse the list of named configuration files, given by + Read and parse the iterable of named configuration files, given by name. A single filename is also allowed. Non-existing files are ignored. Return list of successfully read files. @@ -677,13 +677,13 @@ class RawConfigParser(MutableMapping): return list(opts.keys()) def read(self, filenames, encoding=None): - """Read and parse a filename or a list of filenames. + """Read and parse a filename or an iterable of filenames. Files that cannot be opened are silently ignored; this is - designed so that you can specify a list of potential + designed so that you can specify an iterable of potential configuration file locations (e.g. current directory, user's home directory, systemwide directory), and all existing - configuration files in the list will be read. A single + configuration files in the iterable will be read. A single filename may also be given. Return list of successfully read files. |