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
mypy crashed while checking a file defining a runtime checkable protocol that contained another class.
Traceback
mypy_bug.py:4: error: INTERNAL ERROR -- Please try using mypy master on Github:
https://mypy.rtfd.io/en/latest/common_issues.html#using-a-development-mypy-build
Please report a bug at https://github.com/python/mypy/issues
version: 0.812
Traceback (most recent call last):
File "c:\programdata\anaconda3\envs\sar39\lib\runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\programdata\anaconda3\envs\sar39\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "mypy\checker.py", line 401, in accept
File "mypy\nodes.py", line 950, in accept
File "mypy\checker.py", line 1733, in visit_class_def
File "mypy\checkmember.py", line 966, in type_object_type
File "mypy\typeops.py", line 102, in type_object_type_from_function
File "mypy\typeops.py", line 130, in class_callable
File "mypy\subtypes.py", line 93, in is_subtype
File "mypy\subtypes.py", line 135, in _is_subtype
File "mypy\types.py", line 833, in accept
File "mypy\subtypes.py", line 264, in visit_instance
File "mypy\subtypes.py", line 539, in is_protocol_implementation
AssertionError:
mypy_bug.py:4: : note: use --pdb to drop into pdb
Uh oh!
There was an error while loading. Please reload this page.
Crash Report
mypy crashed while checking a file defining a runtime checkable protocol that contained another class.
Traceback
To Reproduce
Minimal code that causes the error:
Without
@runtime_checkable
, mypy runs fine.Your Environment
mypy mypy_bug.py --show-traceback
.mypy.ini
(and other config files): None. There was no configuration file.The text was updated successfully, but these errors were encountered: