Skip to content

Commit

Permalink
One more place to wrap coroutine in Task before passing to asyncio.wait
Browse files Browse the repository at this point in the history
Needed in Python 3.11+.

QubesOS/qubes-issues#6982

(cherry picked from commit 75f9526)
  • Loading branch information
marmarek committed May 13, 2023
1 parent 2b2ffb9 commit bfa5d6e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion qubes/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -1412,7 +1412,8 @@ async def stop(i):
async with i.startup_lock:
if not i.is_running():
await i.storage.stop()
future = tuple(stop(i) for i in self.domains if i.klass != 'AdminVM')
future = tuple(asyncio.create_task(stop(i)) for i in self.domains
if i.klass != 'AdminVM')
finished = ()
while future:
qubes.utils.systemd_extend_timeout()
Expand Down

0 comments on commit bfa5d6e

Please sign in to comment.