Closed
Description
Dictionary literals with incompatible keys/values result in weird error message, because mypy translate the expression internally to something quite different before type checking.
from typing import Dict
d = {1 : ''} # type: Dict[int, int]
This gives a confusing error message:
t2.py:2: error: List item 0 has incompatible type "Tuple[int, str]"