- Do not use
time.sleep
, or the whole program will be hang. Usesasyncio.sleep
instead. - Remember to add
await
in front ofasyncio.sleep
- Of course, warp code in
async
block as a corouting
time.sleep
, or the whole program will be hang. Uses asyncio.sleep
instead.await
in front of asyncio.sleep
async
block as a corouting
本文标题:Sleep in python asyncio
本文链接:https://www.haomeiwen.com/subject/jxzftxtx.html
网友评论