Replies: 1 comment
-
|
Your If you make the following change in your code, you can eliminate err1 because the type checker will now be able to apply type narrowing to the expression def check_int(i: int | None) -> TypeIs[int]: ... |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
For err1 , I use check_int to check param is int or other. But pyrwight also report an issue . This is an false positive.
For err2, this will casue an runtime error.
Can reportArgumentType distinguish err2 from err1 ? err2 must be resolved, but err1 is not。
Beta Was this translation helpful? Give feedback.
All reactions