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
Allow assignment of types with Nones without explicit annotation
Currently, mypy will not infer types containing None unless they are
valid PartialTypes (i.e. are bare None, list, set, or dict). This means
that all assignments of such types must be explicitly annotated.
It doesn't make sense to require this with strict Optional, as None is a
perfectly valid type. This PR makes types containing None valid
inference targets.
Fixes#2195.
0 commit comments