Open
Description
This code:
async def f() -> None:
pass
async def g() -> None:
f()
is incorrect because f()
isn't awaited. This will produce a runtime warning with the right debug settings, but mypy doesn't give any errors.
It would be nice if mypy could catch this, since I think it's a pretty common error in async code. This could be generalized to warning on other types or function return values that shouldn't be ignored (maybe open
?), similar to __attribute__((warn_unused_result))
in GCC.