From 4e6531e7dee5ff9b27c108e8614d336657e68a21 Mon Sep 17 00:00:00 2001 From: Alexandre Vassalotti Date: Fri, 9 May 2008 20:00:17 +0000 Subject: [PATCH] Removed remnants of os.path.walk(). --- Lib/os.py | 2 +- Mac/Tools/Doc/setup.py | 2 +- Mac/scripts/cachersrc.py | 2 +- Mac/scripts/zappycfiles.py | 2 +- Tools/i18n/pygettext.py | 2 +- Tools/scripts/findlinksto.py | 2 +- Tools/versioncheck/checkversions.py | 2 +- setup.py | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Lib/os.py b/Lib/os.py index 97334f825e9..a4895247954 100644 --- a/Lib/os.py +++ b/Lib/os.py @@ -264,7 +264,7 @@ def walk(top, topdown=True, onerror=None, followlinks=False): from os.path import join, isdir, islink # We may not have read permission for top, in which case we can't - # get a list of the files the directory contains. os.path.walk + # get a list of the files the directory contains. os.walk # always suppressed the exception then, rather than blow up for a # minor reason when (say) a thousand readable directories are still # left to visit. That logic is copied here. diff --git a/Mac/Tools/Doc/setup.py b/Mac/Tools/Doc/setup.py index b020b405f9f..a35152cef10 100644 --- a/Mac/Tools/Doc/setup.py +++ b/Mac/Tools/Doc/setup.py @@ -109,7 +109,7 @@ class DocBuild(build): def hackHtml(self): self.r = re.compile('
') - os.path.walk(self.build_html, self.visit, None) + os.walk(self.build_html, self.visit, None) def visit(self, dummy, dirname, filenames): for f in filenames: diff --git a/Mac/scripts/cachersrc.py b/Mac/scripts/cachersrc.py index e0e84158c67..49a20c06567 100644 --- a/Mac/scripts/cachersrc.py +++ b/Mac/scripts/cachersrc.py @@ -39,7 +39,7 @@ def main(): if o == '-f': force = 1 for dir in sys.argv[1:]: - os.path.walk(dir, handler, (verbose, force)) + os.walk(dir, handler, (verbose, force)) if __name__ == '__main__': main() diff --git a/Mac/scripts/zappycfiles.py b/Mac/scripts/zappycfiles.py index 77258da12af..b377e0d9a8a 100644 --- a/Mac/scripts/zappycfiles.py +++ b/Mac/scripts/zappycfiles.py @@ -22,7 +22,7 @@ def main(): zappyc(dir) def zappyc(dir): - os.path.walk(dir, walker, None) + os.walk(dir, walker, None) def walker(dummy, top, names): for name in names: diff --git a/Tools/i18n/pygettext.py b/Tools/i18n/pygettext.py index 69a19ef9022..4f0866ee10c 100755 --- a/Tools/i18n/pygettext.py +++ b/Tools/i18n/pygettext.py @@ -341,7 +341,7 @@ def getFilesForName(name): if os.path.isdir(name): # find all python files in directory list = [] - os.path.walk(name, _visit_pyfiles, list) + os.walk(name, _visit_pyfiles, list) return list elif os.path.exists(name): # a single file diff --git a/Tools/scripts/findlinksto.py b/Tools/scripts/findlinksto.py index 4fde30ddf34..d3da7e4e113 100755 --- a/Tools/scripts/findlinksto.py +++ b/Tools/scripts/findlinksto.py @@ -22,7 +22,7 @@ def main(): pat, dirs = args[0], args[1:] prog = re.compile(pat) for dirname in dirs: - os.path.walk(dirname, visit, prog) + os.walk(dirname, visit, prog) def visit(prog, dirname, names): if os.path.islink(dirname): diff --git a/Tools/versioncheck/checkversions.py b/Tools/versioncheck/checkversions.py index ccb544d4c13..f110cac3e90 100644 --- a/Tools/versioncheck/checkversions.py +++ b/Tools/versioncheck/checkversions.py @@ -31,7 +31,7 @@ def check1dir(dummy, dir, files): print('** Exception in', fullname) def walk1tree(tree): - os.path.walk(tree, check1dir, None) + os.walk(tree, check1dir, None) def main(): global VERBOSE diff --git a/setup.py b/setup.py index 736fa2128f2..d2e36b487b1 100644 --- a/setup.py +++ b/setup.py @@ -1574,7 +1574,7 @@ class PyBuildInstallLib(install_lib): def set_dir_modes(self, dirname, mode): if not self.is_chmod_supported(): return - os.path.walk(dirname, self.set_dir_modes_visitor, mode) + os.walk(dirname, self.set_dir_modes_visitor, mode) def set_dir_modes_visitor(self, mode, dirname, names): if os.path.islink(dirname): return