From 29cf1e322e115f46e80cb00a247f27ee1077f643 Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Thu, 29 Aug 2024 09:27:14 -0700 Subject: [PATCH] feat: enhance exception handling and issue reporting --- aider/report.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/aider/report.py b/aider/report.py index 6ac832562..716a6cad8 100644 --- a/aider/report.py +++ b/aider/report.py @@ -28,6 +28,7 @@ def report_github_issue(issue_text, title=None): print(f"\n# {title}\n") print(issue_text.strip()) print() + print("Please consider reporting this bug to help improve aider!") prompt = "Report this as a GitHub Issue using your browser? (Y/n) " confirmation = input(prompt).strip().lower() @@ -51,6 +52,9 @@ def report_github_issue(issue_text, title=None): def exception_handler(exc_type, exc_value, exc_traceback): + # We don't want any more exceptions + sys.excepthook = None + # Format the traceback tb_lines = traceback.format_exception(exc_type, exc_value, exc_traceback) tb_text = "".join(tb_lines)