-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
autodoc: Handling of "forward references" for typed functions/methods #8498
Labels
Comments
Is |
Now I'm closing this. Please feel free to reopen if you're still in trouble. |
yes, I believe this occurs also in cases where |
Yes. It must be helpful! |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Describe the bug
If a function/method/etc is typed with an object from another module in the package, this can lead to the reference to that object not yet being available, and thus the referencing fails.
To Reproduce
Create a python module in a package with an object:
package/other.py:
create another module that references that object as a type:
package/main.py:
Then I guess dependent on the order of file parsing / syntax tree assessment, this can lead to:
Expected behavior
The reference for the type should be found.
Your project
I've encountered this in numerous projects, but most recently in aiidateam/aiida-core#4575
Environment info
sphinx.ext.autodoc
The text was updated successfully, but these errors were encountered: