Skip to content

Stop catching generic Exception in triggerer #98

Merged
tatiana merged 10 commits into
mainfrom
issue-81-remove-exceptions
Nov 28, 2024
Merged

Stop catching generic Exception in triggerer #98
tatiana merged 10 commits into
mainfrom
issue-81-remove-exceptions

Conversation

@tatiana
Copy link
Copy Markdown
Collaborator

@tatiana tatiana commented Nov 28, 2024

By catching Exception, we risk hitting an unexpected exception that the program can't recover from, or worse, swallowing an important exception without properly logging it - a massive headache when trying to debug programs that are failing in weird ways.

If this change leads to any exceptions that should be caught being raised, we'll have the opportunity to understand which are those exceptions and capture them, handling them in a graceful way.

This was identified during #81 development.

Comment thread tests/test_triggers.py Outdated
Comment thread tests/test_triggers.py Outdated
Comment thread tests/test_triggers.py Outdated
Comment thread tests/test_triggers.py Outdated
Comment thread tests/test_triggers.py Outdated
Comment thread tests/test_triggers.py
Copy link
Copy Markdown
Contributor

@pankajastro pankajastro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just have a minor question otherwise looking good

Comment thread ray_provider/constants.py Outdated
Comment thread ray_provider/triggers.py
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Nov 28, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.74%. Comparing base (b200897) to head (866cbc9).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #98      +/-   ##
==========================================
- Coverage   98.22%   97.74%   -0.49%     
==========================================
  Files           5        6       +1     
  Lines         564      576      +12     
==========================================
+ Hits          554      563       +9     
- Misses         10       13       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

By catching `Exception`, we run into the ristk of hitting an unexpected exception that the program can't recover from, or worse, swallowing an important exception without properly logging it - a huge headache when trying to debug programs that are failing in weird ways

This was identified during #81 development.
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.

3 participants