Skip to content

Commit

Permalink
Avoid division by zero
Browse files Browse the repository at this point in the history
  • Loading branch information
FreddieAkeroyd authored Dec 20, 2024
1 parent 44b4bc4 commit ee1315e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion developer_support_script/check_build_stability.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def print_results(self) -> None:
# Aborted builds.
valid_builds = self.num_evaluate_builds + self.no_test_report_failures
all_builds = valid_builds + self.num_aborted_builds
percentage_aborted_builds = (self.num_aborted_builds / all_builds) * 100
percentage_aborted_builds = (self.num_aborted_builds / all_builds) * 100 if all_builds > 0 else 0
level = calculate_level(
percentage_aborted_builds, ERROR_THRESHOLD_PERCENTAGE, WARNING_THRESHOLD_PERCENTAGE
)
Expand Down

0 comments on commit ee1315e

Please sign in to comment.