Skip to content

Commit

Permalink
Fix sys.excepthook_org handling (#149)
Browse files Browse the repository at this point in the history
It might not be set, depending on where the exception was raised.
  • Loading branch information
albertz authored Sep 18, 2023
1 parent bcb9a94 commit adadf2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sisyphus/loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def load_config_file(self, config_name):
except SyntaxError:
import sys

if gs.USE_VERBOSE_TRACEBACK:
if gs.USE_VERBOSE_TRACEBACK and getattr(sys, "excepthook_org", None) is not None:
sys.excepthook = sys.excepthook_org
raise

Expand Down

0 comments on commit adadf2c

Please sign in to comment.