-
Notifications
You must be signed in to change notification settings - Fork 32
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
Add mypy checking #90
Conversation
Co-authored-by: Brendan <[email protected]>
I've been trying to fix the typing in json_domain.py (pyright and I are having problems understanding it)... I see you've made some significant changes to that file here - some of which doesn't seem related to typing. For now, I'll just use |
I removed |
oh I see; I just type ignored that param because I'm not sure how to tell pyright that it is a class (not an instance of a class). I did some type aliasing to cpp_domain_fixes.py and found that pyright doesn't like using a module's namespace ( |
I'm not sure which parameter you're referring to, but |
I've been going through and adding types to all function params. I have pyright to emit this violation as a warning so builds still pass, but it helps me understand the focus of a function without having to backtrack what was passed to it (in trying to understand what the function is doing with the param). |
I think the correct type for that would be: Not clear if it will handle that, though. |
Nevermind, I see that that Maybe |
tried that. pyright says that
also tried
In fact, the CI log errored out when I combined There really isn't many
because the parameter is well named enough |
Hey! domain_module: ModuleType, # Union[sphinx.domains.c, sphinx.domains.cpp] I put the |
I made some changes:
|
Thanks! This looks good to me. |
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.
ready to merge when you are
No description provided.