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
os.walk example for deleting a full tree is sometime wrong #41204
Comments
On page: http://docs.python.org/lib/os-file-dir.html the example give: ... This don't work if one link exist in the tree pointing The given recipe will work until /tmp/mydir/toto is an One solution can be: Another better thing is to use os.path.join() instead |
Logged In: YES Shrug -- the point of the example is the need for WRT join(), the example is already using os.path.join(). The from os.path import join establishes "join" as a short name for os.path.join. |
Logged In: YES Hi, thanks for this quick answer. I agree with you that this is And sorry for the join. I have missing the from os.path Good day. |
Logged In: YES OK, I added words about links, and changed the example to Doc/lib/libos.tex 1.145 |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: