Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

calc: gracefully handle ExpressionEvaluator.Error #2507

Merged
merged 1 commit into from
Sep 27, 2023
Merged

Conversation

dgw
Copy link
Member

@dgw dgw commented Sep 21, 2023

Description

Replaced fallthrough to Sopel's bot-level "Unexpected Error" handler with a more graceful presentation of the error message.

Checklist

  • I have read CONTRIBUTING.md
  • I can and do license this contribution under the EFLv2
  • No issues are reported by make qa (runs make lint and make test)
  • I have tested the functionality of the things this change touches

Notes

We might consider making this exception a standalone class, for less wacky-looking error handling in this and other consumers of the tools.calculation submodule. Doing except a_function.Subclass feels weird and wrong.

@dgw dgw added the Tweak label Sep 21, 2023
@dgw dgw added this to the 8.0.0 milestone Sep 21, 2023
@dgw dgw requested a review from a team September 21, 2023 06:58
We might consider making this exception a standalone class, for less
wacky-looking error handling in this and other consumers of the
`tools.calculation` submodule. Doing `except a_function.Subclass` feels
weird and wrong.
@dgw dgw merged commit 8c3e533 into master Sep 27, 2023
7 checks passed
@dgw dgw deleted the calc-error-handler branch September 27, 2023 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants