-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
DOC: Explain leading dot in object references #27945
Conversation
doc/devel/document.rst
Outdated
the leading dot, otherwise Sphinx will try to resolve the object only in the current | ||
module. See also the explanation at `Sphinx: Cross-referencing Python objects |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Um, I'm not sure what this means, feel like either it needs more detail (short example) or should be left out
the leading dot, otherwise Sphinx will try to resolve the object only in the current | |
module. See also the explanation at `Sphinx: Cross-referencing Python objects | |
the leading dot, as discussed in `Sphinx: Cross-referencing Python objects |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in a sphinx page you can set a "current module", if you don't use the .
it looks for the name in that module, if you use the dot it will look anythere in your project.
I think this is clear enough as-is and removing this bit of the text makes this PR mostly content-less.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is clear enough as-is
You also already knew what it was getting it, while I didn't and found this explanation hard to follow. Granted, I think the explanation you just wrote "if you don't use the . it looks for the name in that module, if you use the dot it will look anythere in your project." is what I was after.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reworded to
Note that you should typically include
the leading dot. It tells Sphinx to look for the given name in the whole project.
No description provided.