MyPy Exception Type Error Message Update#15131
Conversation
This comment has been minimized.
This comment has been minimized.
|
Thanks for the PR! Can you update the failing tests to use the new error message? |
Absolutely! I just updated the test cases :) |
This comment has been minimized.
This comment has been minimized.
hauntsaninja
left a comment
There was a problem hiding this comment.
This looks great, thank you!
One possible nit: maybe "or be a tuple of exception classes"? I think the additional "be" makes it clearer in the presence of "derived"
That's an easy adjustment. I'll do that now. |
|
Diff from mypy_primer, showing the effect of this PR on open source code: packaging (https://github.com/pypa/packaging) got 30.10 faster (3.7s -> 0.1s)
vision (https://github.com/pytorch/vision) got 1.20 slower (28.4s -> 34.0s)
|
|
(We're experimenting with reporting CI time differences, the performance numbers here are just noise) |
Fixes #5349 - Updating Error Messaging for Invalid Exception Type