-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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 extra overload for to_netcdf #8268
Conversation
The current signature does not match with pyright if a non literal bool is passed.
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.
There are still some Mypy errors. Maybe my comment fixed them, maybe not, maybe it creates new problems.
Also, feel free to add an entry in whats-new!
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 took the liberty to fix the open problems.
Good to go now!
On a side note, maybe I will open an issue over at mypy to request the feature that Union[Literal[True], Literal[False]] == bool
Already exists: python/mypy#14764 |
Thanks! |
@headtr1ck thanks for finishing this. Sorry for dropping the ball on it |
The current signature does not match with pyright if a non-literal bool is passed.
This fixes type checking of code like this:
with pyright.
See microsoft/pyright#6069 for context.