mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 16:54:59 +00:00
feat: handle KeyboardInterrupt with default exception handler
This commit is contained in:
parent
3b045a2cef
commit
0df97c3241
1 changed files with 4 additions and 0 deletions
|
@ -89,6 +89,10 @@ def report_github_issue(issue_text, title=None):
|
|||
|
||||
|
||||
def exception_handler(exc_type, exc_value, exc_traceback):
|
||||
# If it's a KeyboardInterrupt, just call the default handler
|
||||
if issubclass(exc_type, KeyboardInterrupt):
|
||||
return sys.__excepthook__(exc_type, exc_value, exc_traceback)
|
||||
|
||||
# We don't want any more exceptions
|
||||
sys.excepthook = None
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue