A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-May/035589.html below:

[Python-Dev] os.path.walk() lacks 'depth first' option

[Python-Dev] os.path.walk() lacks 'depth first' option [Python-Dev] os.path.walk() lacks 'depth first' optionWalter Dörwald walter@livinglogic.de
Tue, 13 May 2003 18:36:18 +0200
Guido van Rossum wrote:

 >> I like the increased flexibility. But how about the following
 >> version?
 >
 >
 > I don't think there's any need for such increased flexibility.  Let's
 > stop while we're ahead.  Fixing the silent errors case is important
 > (see various posts here).  Your generalization is a YAGNI though.

True, getting a list of files in the current directory even works
with the current os.walk:

sum([[os.path.join(x[0], f) for f in x[2]] for x in os.walk(".")], [])

Bye,
    Walter Dörwald






RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4