strict mode vs. pytest.raises(parametrised exc type) #10774
Unanswered
Dima Tisnek (dimaqq)
asked this question in
Q&A
Replies: 0 comments
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.
Uh oh!
There was an error while loading. Please reload this page.
This code doesn't pass pyright in stict mode:
I can change it like this:
But then it fails at runtime:
What's the correct way to handle this?
P.S. the exception is declared like so:
All reactions