From 26b4ff1df23ac6a2c025ffb44ed5e0bb3e07098a Mon Sep 17 00:00:00 2001 From: Doug Hoskisson Date: Wed, 16 Aug 2023 07:00:10 -0700 Subject: [PATCH] Zillion: Python 3.11 compatibility fix (#2105) --- ZillionClient.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ZillionClient.py b/ZillionClient.py index 92585d31..7d32a722 100644 --- a/ZillionClient.py +++ b/ZillionClient.py @@ -423,9 +423,9 @@ async def zillion_sync_task(ctx: ZillionContext) -> None: async_start(ctx.send_connect()) log_no_spam("logging in to server...") await asyncio.wait(( - ctx.got_slot_data.wait(), - ctx.exit_event.wait(), - asyncio.sleep(6) + asyncio.create_task(ctx.got_slot_data.wait()), + asyncio.create_task(ctx.exit_event.wait()), + asyncio.create_task(asyncio.sleep(6)) ), return_when=asyncio.FIRST_COMPLETED) # to not spam connect packets else: # not correct seed name log_no_spam("incorrect seed - did you mix up roms?") @@ -447,9 +447,9 @@ async def zillion_sync_task(ctx: ZillionContext) -> None: ctx.known_name = name async_start(ctx.connect()) await asyncio.wait(( - ctx.got_room_info.wait(), - ctx.exit_event.wait(), - asyncio.sleep(6) + asyncio.create_task(ctx.got_room_info.wait()), + asyncio.create_task(ctx.exit_event.wait()), + asyncio.create_task(asyncio.sleep(6)) ), return_when=asyncio.FIRST_COMPLETED) else: # no name found in game if not help_message_shown: