unpacking assignment with self
annotated as typing.Self
in typing.NamedTuple
subclass method causes mypy internal error
#17010
Labels
Crash Report
Inside of
typing.NamedTuple
subclass methods, unpacking assignments withself
annotated astyping.Self
on the right-hand side causes mypy to fail (internal error).Traceback
To Reproduce
mypy-play gist
mypy-play playground
Alternate example showing that this can occur even when
self
is not directly annotated astyping.Self
:alternate example mypy-play gist
alternate example mypy-play playground
Your Environment
mypy.ini
(and other config files):The text was updated successfully, but these errors were encountered: