The below Python 3.12 code with ruff==0.5.2:
import asyncio
async def foo() -> None:
async with asyncio.timeout(2.0), asyncio.TaskGroup() as tg:
tg.create_task(asyncio.sleep(1))
Will throw an ASYNC100 error on the fourth line:
a.py:4:5: ASYNC100 A `with asyncio.timeout(...):` context does not contain any `await` statements. This makes it pointless, as the timeout can only be triggered by a checkpoint.
I think this is a false positive, as the inner asyncio.TaskGroup has an implicit await during its __exit__