Skip to content

fix: replace bare except: with except Exception#3

Open
AmSach wants to merge 1 commit intodsdanielpark:mainfrom
AmSach:fix/bare-except-catching-system-exits
Open

fix: replace bare except: with except Exception#3
AmSach wants to merge 1 commit intodsdanielpark:mainfrom
AmSach:fix/bare-except-catching-system-exits

Conversation

@AmSach
Copy link
Copy Markdown

@AmSach AmSach commented May 5, 2026

Fixed a bug I found while browsing. The code used bare except: clauses which catch SystemExit and KeyboardInterrupt exceptions that should propagate normally. Changed except: to except Exception: in two places in discord_notifier.py.

This prevents the exception handler from silently catching SystemExit (e.g., from sys.exit()) and KeyboardInterrupt (Ctrl+C), allowing them to propagate properly.

— Sent via @AmSach bot

@codacy-production
Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 7 complexity · -3 duplication

Metric Results
Complexity 7
Duplication -3

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant