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
{{ message }}
Repository navigation
False error in conditional expression returning union #6898
Are you reporting a bug, or opening a feature request?
Bug
Please insert below the code you are checking with mypy,
or a mock-up repro if the source is private. We would appreciate
if you try to simplify your case to a minimal repro.
The tuple example is a separate (relatively simple, but old) issue. The original example is just another case (among dozens) where single-bin inference would help.
I'm getting `Argument 1 to "func" has incompatible type "Union[str, float]"; expected "str" [arg-type]'. Is this related as well? Am I doing something wrong?
Activity
ilevkivskyi commentedon May 26, 2019
The tuple example is a separate (relatively simple, but old) issue. The original example is just another case (among dozens) where single-bin inference would help.
I think we should really do this.
utkarshgupta137 commentedon Jun 8, 2021
I'm getting `Argument 1 to "func" has incompatible type "Union[str, float]"; expected "str" [arg-type]'. Is this related as well? Am I doing something wrong?
Use union of current context and left side for right side narrowing o…