New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sort directories returned by os.walk #1

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
2 participants
@madsushi

madsushi commented Feb 25, 2016

When Python returns directories from os.walk (which uses os.listdir),
they are in an arbitrary order on some OSes (Ubuntu, etc) per the Python
documentation. Adding a .sort() in the process resolves this issue,
ensuring that directories are sorted properly and processed in the
correct order.

Sort directories returned by os.walk
When Python returns directories from os.walk (which uses os.listdir),
they are in an arbitrary order on some OSes (Ubuntu, etc) per the Python
documentation. Adding a .sort() in the process resolves this issue,
ensuring that directories are sorted properly and processed in the
correct order.
@sjl

This comment has been minimized.

Owner

sjl commented Nov 24, 2016

I've moved to Hugo for my blog, so this repo is basically abandonware at this point, especially since it was a fork of the already-abandoned old version of Hyde.

@sjl sjl closed this Nov 24, 2016

@madsushi

This comment has been minimized.

madsushi commented Nov 24, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment