-
-
Notifications
You must be signed in to change notification settings - Fork 2k
sum stub too permissive #7574
Copy link
Copy link
Closed
Labels
stubs: false negativeType checkers do not report an error, but shouldType checkers do not report an error, but should
Metadata
Metadata
Assignees
Labels
stubs: false negativeType checkers do not report an error, but shouldType checkers do not report an error, but should
Fields
Give feedbackNo fields configured for issues without a type.
Currently the stub for the
sumbuilt-in allows any iterable as an argumenttypeshed/stdlib/builtins.pyi
Lines 1480 to 1489 in ae6ff79
This means mypy has no issue with:
Which results in this error at runtime:
context: I was introducing someone to mypy and used the example above as something that mypy should flag, but turns out it wasn't being flagged so logging here.