也许,时间见过我们

只是参考快速跑起来模版,细节或者封装流畅使用需要详细阅读aiohttp文档

1 import asyncio
2 
3 async def foo():
4        await print('bar')
5 
6 loop = asyncio.get_event_loop()
7 future = asyncio.ensure_future(foo())
8 loop.run_until_complete(future);

 

posted on 2020-10-22 16:53  画入新雪  阅读(123)  评论(0编辑  收藏  举报

Copyright ©2017 画入新雪