Bug Report
(A clear and concise description of what the bug is.)
To Reproduce
from __future__ importannotationsfromtypingimportProtocolclassDemo(Protocol):
@staticmethoddefdemo(v: int) ->int:
passdefreturns_one(v: int) ->int:
return1classInheriting(Demo):
demo=staticmethod(returns_one)
https://mypy-play.net/?mypy=latest&python=3.9&gist=1438683686842d8a03bfbc32646c7952&flags=strict
Expected Behavior
Success: no issues found in 1 source file
Actual Behavior
main.py:15: error: Incompatible types in assignment (expression has type "staticmethod[[int], int]", base class "Demo" defined the type as "Callable[[int], int]") [assignment]
Your Environment
- Mypy version used: 1.3.0
- Mypy command-line flags:
- Mypy configuration options from
mypy.ini (and other config files): - Python version used: 3.9
Bug Report
(A clear and concise description of what the bug is.)
To Reproduce
https://mypy-play.net/?mypy=latest&python=3.9&gist=1438683686842d8a03bfbc32646c7952&flags=strict
Expected Behavior
Success: no issues found in 1 source file
Actual Behavior
main.py:15: error: Incompatible types in assignment (expression has type "staticmethod[[int], int]", base class "Demo" defined the type as "Callable[[int], int]") [assignment]Your Environment
mypy.ini(and other config files):