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
intgr
changed the title
Assert on literal field causes spurious "Non-overlapping equality check"
Assert on Literal field causes spurious "Non-overlapping equality check"
Sep 3, 2020
🐛 Bug Report
Mypy is overzealous in constraining the possible values of a
Literal
field, assuming that it cannot change after beingassert
ed.I suppose this can also happen with other types, like
Union
fields, but in the case ofLiteral
it's particularly awkward.To Reproduce
The text was updated successfully, but these errors were encountered: