Closed
Description
Even after PR #4650, the stubs for aiofiles are incorrect.
The stubs still don't include wrapped methods for AsyncBufferedReader, AsyncBufferedIOBase, AsyncBufferedReader and AsyncFileIO. Something like this doesn't type check, since, according to current stubs, AsyncBufferedReader has no read method:
import aiofiles
async def print_file(path: str) -> None:
async with aiofiles.open(path, mode="r") as f:
print(await f.read())
And also, there's no aiofiles._os
module, it should be aiofiles.os
.