We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
please include in the docs how to write to stdout. here is a snippent of how i did it , wrap isn't documented.
`import asyncio from email import contentmanager import aiohttp import aiofiles from aiofiles.os import wrap import sys import os
aio_write = aiofiles.os.wrap(os.write)
async def main(): async with aiofiles.open("sample.txt") as f: #contents=await f.read() write_stdout=wrap(sys.stdout.write) print_stdout=wrap(print)
async for contents in f: await write_stdout(contents) #await print_stdout(f"stdout test")
asyncio.run(main())`
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
please include in the docs how to write to stdout. here is a snippent of how i did it , wrap isn't documented.
`import asyncio
from email import contentmanager
import aiohttp
import aiofiles
from aiofiles.os import wrap
import sys
import os
aio_write = aiofiles.os.wrap(os.write)
async def main():
async with aiofiles.open("sample.txt") as f:
#contents=await f.read()
write_stdout=wrap(sys.stdout.write)
print_stdout=wrap(print)
asyncio.run(main())`
The text was updated successfully, but these errors were encountered: