closes bpo-33202: fix os.walk mentioning os.listdir instead of os.scandir (GH-6335)

(cherry picked from commit badb894bbb)

Co-authored-by: Andrés Delfino <34587441+andresdelfino@users.noreply.github.com>
This commit is contained in:
Miss Islington (bot) 2018-04-02 20:33:38 -07:00 committed by GitHub
parent de755129a7
commit f6d1d65803
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -2812,7 +2812,7 @@ features:
no effect on the behavior of the walk, because in bottom-up mode the directories no effect on the behavior of the walk, because in bottom-up mode the directories
in *dirnames* are generated before *dirpath* itself is generated. in *dirnames* are generated before *dirpath* itself is generated.
By default, errors from the :func:`listdir` call are ignored. If optional By default, errors from the :func:`scandir` call are ignored. If optional
argument *onerror* is specified, it should be a function; it will be called with argument *onerror* is specified, it should be a function; it will be called with
one argument, an :exc:`OSError` instance. It can report the error to continue one argument, an :exc:`OSError` instance. It can report the error to continue
with the walk, or raise the exception to abort the walk. Note that the filename with the walk, or raise the exception to abort the walk. Note that the filename