Ben Hoyt <benhoyt at gmail.com> writes: > Hi Python dev folks, > > I've written a PEP proposing a specific os.scandir() API for a > directory iterator that returns the stat-like info from the OS, *the > main advantage of which is to speed up os.walk() and similar > operations between 4-20x, depending on your OS and file system.* > ... > http://legacy.python.org/dev/peps/pep-0471/ > ... > Specifically, this PEP proposes adding a single function to the ``os`` > module in the standard library, ``scandir``, that takes a single, > optional string as its argument:: > > scandir(path='.') -> generator of DirEntry objects > Have you considered adding support for paths relative to directory descriptors [1] via keyword only dir_fd=None parameter if it may lead to more efficient implementations on some platforms? [1]: https://docs.python.org/3.4/library/os.html#dir-fd -- akira
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