reportArgumentType false trigger despite guard type narrowing code #7451
Closed
kiml
started this conversation in
Enhancement
Replies: 1 comment 2 replies
-
I don't believe that's a supported Type guard (for a python type checker). Supported type guards are described here: |
Beta Was this translation helpful? Give feedback.
2 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.
-
When safety checking multiple values for None I've taken to using the following idiom in many cases (which I find quite neat) but pylance doesn't recognise it as a type narrowing guard.
The simplest test case would be:
Beta Was this translation helpful? Give feedback.
All reactions