Fixed an issue in the main script causing the sys.excepthook() function set by the debugger being overwritten. That caused eric not being able to debug eric. eric7

Fri, 02 Feb 2024 13:33:55 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 02 Feb 2024 13:33:55 +0100
branch
eric7
changeset 10541
b709f6cc205c
parent 10540
7631c0ba2877
child 10542
e46910b0ce73

Fixed an issue in the main script causing the sys.excepthook() function set by the debugger being overwritten. That caused eric not being able to debug eric.

src/eric7/eric7_ide.py file | annotate | diff | comparison | revisions
--- a/src/eric7/eric7_ide.py	Fri Feb 02 13:32:36 2024 +0100
+++ b/src/eric7/eric7_ide.py	Fri Feb 02 13:33:55 2024 +0100
@@ -329,7 +329,9 @@
 
     global app, args, mainWindow, splash, restartArgs, inMainLoop
 
-    sys.excepthook = excepthook
+    if sys.excepthook is sys.__excepthook__:
+        # we are not executed in the debugger - set our exception hook
+        sys.excepthook = excepthook
     if OSUtilities.isLinuxPlatform() or OSUtilities.isFreeBsdPlatform():
         multiprocessing.set_start_method("spawn")
 

eric ide

mercurial