On Mon, May 13, 2013 at 10:25 PM, Ben Hoyt <benh...@gmail.com> wrote:
> Okay, I've renamed my "BetterWalk" module to "scandir" and updated it
> as per our discussion:
>
> https://github.com/benhoyt/scandir/#readme

Nice!

> PERFORMANCE: On Windows I'm seeing that scandir.walk() on a large test
> tree (see benchmark.py) is 8-9 times faster than os.walk(), and on
> Linux it's 3-4 times faster. Yes, it is that much faster, and yes,
> those numbers are real. :-)

I'd to see the numbers for NFS or CIFS - stat() can be brutally slow
over a network connection (that's why we added a caching mechanism to
importlib).

> Please critique away. At this stage it'd be most helpful to critique
> any API or performance-related issues rather than coding style or
> minor bugs, as I'm expecting the code itself will change quite a bit
> still.

I initially quite liked the idea of not offering any methods on
DirEntry, only properties, to make it obvious that they don't touch
the file system, but just report info from the scandir call. However,
I think that it ends up reading strangely, and would be confusing
relative to the os.path() APIs.

What you have now seems like a good, simple alternative.

Cheers,
Nick.

--
Nick Coghlan   |   ncogh...@gmail.com   |   Brisbane, Australia
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to