Fix deprecated asyncio.wait use with coroutines (#44981)

https://docs.python.org/3/library/asyncio-task.html#asyncio-example-wait-coroutine
This commit is contained in:
Ville Skyttä
2021-02-10 15:16:58 +02:00
committed by GitHub
parent 4b493c5ab9
commit a6358430b4
11 changed files with 17 additions and 13 deletions

View File

@@ -1055,7 +1055,7 @@ class Script:
raise
async def _async_stop(self, update_state):
aws = [run.async_stop() for run in self._runs]
aws = [asyncio.create_task(run.async_stop()) for run in self._runs]
if not aws:
return
await asyncio.wait(aws)