Skip to content

Detect unawaited coroutines #9833

@alekssamos

Description

@alekssamos

Hello. I fixed my code via ruff.
Applied fix and unsafe fixes.
But ruff did not find one error.
I forgot to write await when calling an asynchronous function.
Accordingly, I received RuntimeWarning never awaited...
e.g.

async def another():
    ...

async def main():
    result = another()

Is there any way to do this, and if not, will it be taken into account in the new versions of ruff?

Metadata

Metadata

Assignees

Labels

ruleImplementing or modifying a lint ruletype-inferenceRequires more advanced type inference.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions