Looks like we have a typeshed bug:
from unittest.mock import patch
def addition(a: int, b:int) -> int:
return a+b
@patch('test.addition')
def patch_test(mock):
print(mock)
if __name__ == "__main__":
patch_test()
In this simple example mypy says:
test.py:12: error: Missing positional argument "mock" in call to "patch_test" [call-arg]
Undoing 9e86c60 fixes it