【 在 ToSimplicity 的大作中提到: 】
: [code=py]
: #
: import asyncio
: ...................
我的逻辑里有一个while true,这样就跳不出去了
async def do_while_true_tasks(name):
while True:
print(f'# Project <{name}> starts.')
for i in range(5):
await do_cpu_intense_unit_work(f'project {name} -> step {i}')
await asyncio.sleep(0)
print(f'# Project <{name}> ends.')
--
FROM 112.45.96.*