From 5f92931d32568d63d15285d628604963b0b6e7e5 Mon Sep 17 00:00:00 2001 From: Pekka T Savolainen Date: Fri, 20 Dec 2024 13:04:55 +0200 Subject: [PATCH] Set event_loop_policy only on Windows --- spinetoolbox/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spinetoolbox/main.py b/spinetoolbox/main.py index c946b7297..4b27fb187 100644 --- a/spinetoolbox/main.py +++ b/spinetoolbox/main.py @@ -39,8 +39,9 @@ def main(): """Creates main window GUI and starts main event loop.""" - asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy()) multiprocessing.freeze_support() + if sys.platform == "win32": + asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy()) logging.basicConfig( stream=sys.stderr, level=logging.DEBUG,