-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
Reorganize os.path
documentation
#130536
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
Comments
I think A |
To me it's indeed the case. I know that we have Ctrl+F to find in the page, but I also know people that are happy when it's alphabetically organized. I'll quickly check which function needs cross-ref with |
Ok, there's not much content to update. I've written down what needs to be done (roughly), maybe there are other places that could be improved. I'll stil mark this one as easy. |
Maybe split the docs into lexical functions ( |
The
os.path
documentation is alphabetically sorted. That's great because it's easy to find a function. However, this also means that functions shouldn't reference other functions documented later as the reader may not have been aware of them before.An alternative is to reorganize the documentation page so that we put at the top the most used functions such as
os.path.join
. The latter caused a bit of confusion in gh-130527, where neither the OP nor me remembered thatos.path.join("/a", "/b") == "/b"
.If reorganizing the documentation is not preferred, we should at least add
.. seealso::
directives and clickable links so that any function mentioned but not yet documented at the time of reading can be easily looked up.os.path.join
without a link.os.path.abspath
.os.path.join
but as it's far away, we could backlink it.os.path.join("/home/foo", "/home/bar") == "/home/bar"
.Linked PRs
os.path
documentation #130557The text was updated successfully, but these errors were encountered: