diff --git a/FreeSimpleGUI/window.py b/FreeSimpleGUI/window.py index f8402df3..b6039461 100644 --- a/FreeSimpleGUI/window.py +++ b/FreeSimpleGUI/window.py @@ -1087,7 +1087,7 @@ def _read(self, timeout=None, timeout_key=TIMEOUT_KEY): Window._root_running_mainloop.mainloop() except: print('**** EXITING ****') - exit(-1) + sys.exit(-1) # print('Out main') self.CurrentlyRunningMainloop = False # if self.LastButtonClicked != TIMEOUT_KEY: