只是参考快速跑起来模版,细节或者封装流畅使用需要详细阅读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);
------
往事如烟,伴着远去的步伐而愈加朦胧。未来似雾,和着前进的风儿而逐渐清晰!