-
Notifications
You must be signed in to change notification settings - Fork 8
fix: resolve type checking errors #856
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
base: main
Are you sure you want to change the base?
Conversation
Revathyvenugopal162
commented
Dec 17, 2025
- Add missing type stubs for PyYAML and docutils
- Fix type annotations in whatsnew.py, navbar_dropdown.py, linkcode.py
- Resolve return type issues and missing return statements
- Fix Path/string conversion issues
- Add proper Iterator type annotations
- Add missing type stubs for PyYAML and docutils - Fix type annotations in whatsnew.py, navbar_dropdown.py, linkcode.py - Resolve return type issues and missing return statements - Fix Path/string conversion issues - Add proper Iterator type annotations
|
Pull request documentation preview limit (20) reached: skipping documentation deployment for this pull request. |
|
merge after #804 |
jorgepiloto
left a comment
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.
How did you find these issues?
| Application instance for rendering the documentation. | ||
| """ | ||
| autoapi = config.html_theme_options.get("ansys_sphinx_theme_autoapi", {}) | ||
| autoapi = app.config.html_theme_options.get("ansys_sphinx_theme_autoapi", {}) |
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 am surprised about this. This is not a type hint error. It is a different object.
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 mypy raised this error due to an object type mismatch. We typed config as a dict, but later we tried to access its attributes, which caused the mypy error. In practice, both approaches behave the same in this case, so I added the change. We can safely ignore this mypy error.
I ran mypy in my local environment, where some modules are type-hinted and others are not. |
Let's take advantage of this pull-request to implement type checking via pre-commit. We could try ty for this. |