Skip to content

Commit

Permalink
Add error message to runtime error in rounder
Browse files Browse the repository at this point in the history
  • Loading branch information
paul019 committed Mar 16, 2024
1 parent c201917 commit 89e6c17
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/application/rounder.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,9 @@ def _round_result(cls, result: Result, config: RoundingConfig) -> None:
value.set_min_exponent(min_exponent)

else:
raise RuntimeError # TODO: add message (!)
# This branch cannot be reached, because the config makes sure that
# either`sigfigs_fallback` or `decimal_places_fallback` is set.
raise RuntimeError("An unexpected error occurred. Please report this bug.")

@classmethod
def _uncertainties_set_min_exponents(
Expand Down

0 comments on commit 89e6c17

Please sign in to comment.