You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
No error in the ternary case. (Well, would be amazing to have singledispatch handle this so I don't have to write code like this, but that's not a discussion for here...)
Actual Behavior
playground.py:23: error: Argument 1 to "handle_str" has incompatible type "List[str]"; expected "str"
playground.py:23: error: Argument 1 to "handle_list" has incompatible type "str"; expected "List[Any]"
Your Environment
Mypy version used: mypy==0.910
Mypy command-line flags: None
Mypy configuration options from mypy.ini (and other config files): ignore_missing_imports = True
Python version used: Python 3.9.6
Operating system and version: Manjaro Linux x86_64
The text was updated successfully, but these errors were encountered:
Bug Report
Two different results depending on whether a ternary operator or a simple if-else block is used.
To Reproduce
raises errors only in the second case.
Expected Behavior
No error in the ternary case. (Well, would be amazing to have
singledispatch
handle this so I don't have to write code like this, but that's not a discussion for here...)Actual Behavior
Your Environment
mypy==0.910
mypy.ini
(and other config files):ignore_missing_imports = True
The text was updated successfully, but these errors were encountered: