-
Notifications
You must be signed in to change notification settings - Fork 2
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: provide type aliases for common classes #400
Conversation
…s/type-declarations
A somewhat unexpected test failure on macOS / Python 3.6:
Looks like IPC on the macOS runners runs very slowly indeed. |
This comment has been minimized.
This comment has been minimized.
Some of those are expected - this PR doesn't yet claim to eliminate all warnings. But it should be eliminating these ones:
What version of Sphinx are you using? |
This comment has been minimized.
This comment has been minimized.
…t earlier versions of Sphinx
This comment has been minimized.
This comment has been minimized.
Sigh. Even after pulling the latest changes, i'm still seeing the same errors mark :/ What do you think we should do here.
|
@rahulporuri What version of Sphinx are you using? It's noticeable that the |
@rahulporuri One last try. I'm guessing that you were using Sphinx 3.5.x. For me, this last change works with both Sphinx 3.5 and Sphinx >= 4. I'm suspecting that the form of reference I was seeing in Sphinx 4 was actually due to a bug. |
Sorry for the guessing game but I'm using the latest version of sphinx on edm - 3.5.4-2. Testing the latest changes. |
Yes, sorry; it took me a while to realise you were using the |
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.
🎉 LGTM 🎉
For future reference, I am almost always using the ci commands. |
This PR adds type aliases for expanding common classes, so that a type declaration like:
doesn't complain about the unknown class
TraitsExecutor
.It also sets
napoleon_preprocess_types = True
, which in addition to expanding the aliases, prevents Napoleon / autodoc complaining about the "optional" in type signatures like "float, optional".Update: we also add a
nitpick_ignore_regex
definition to let us ignore autodoc-generated references to base classes fromPyside2
,Pyface
andwx
.