Author vstinner
Recipients benhoyt, python-dev, scott.dial, vstinner
Date 2015-03-10.12:26:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
My suggestion to add a new walk_dirs list is wrong: os.walk() documentation explicitly says that the dirs list can be modified to delete some directories:
When topdown is True, the caller can modify the dirnames list in-place (perhaps using del or slice assignment), and walk() will only recurse into the subdirectories whose names remain in dirnames; this can be used to prune the search, impose a specific order of visiting, or even to inform walk() about directories the caller creates or renames before it resumes walk() again.

os_walk_1.patch is inefficient: it also calls entry.is_symlink() for file entries.

I reworked your patch to only call is_symlink() for directories.

Thanks for the patch Ben. I think that we are now done with the PEP 471 no? Maybe some doc changes (I'm now reviewing your doc change in issue #22524).
Date User Action Args
2015-03-10 12:26:55vstinnersetrecipients: + vstinner, scott.dial, benhoyt, python-dev
2015-03-10 12:26:55vstinnersetmessageid: <>
2015-03-10 12:26:55vstinnerlinkissue23605 messages
2015-03-10 12:26:54vstinnercreate