-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
(🐞) Bad error message when using Concatenate
incorrectly
#13518
Comments
@sobolevn Should the message |
I think this is correct 🤔 |
Does MyPy actually support |
Fixes #14761 Fixes #15318 Fixes #14656 Fixes #13518 I noticed there is a bunch of inconsistencies in `semanal`/`typeanal` for ParamSpecs, so I decided do a small cleanup. Using this opportunity I also allow `Concatenate[int, ...]` (with literal Ellipsis), and reduce verbosity of some errors. cc @A5rocks
Despite the fact that a good message is output afterwards, the initial error seems like nonsense: "first arg to Callable must be a parameter specification". Huh? it is a
ParamSpec
?! I presume that this is because the type becomesAny (from error)
due to the args being invalid. At runtime the type here would beNever
(because it wouldraise
).playground
The text was updated successfully, but these errors were encountered: