Answer principles round 2: 0 🔴, 0 🟡 (0 misread); read the preloaded files before the scoring worktree is made, and state Route's contract
CI / tests (pull_request) Successful in 2m58s

This commit is contained in:
2026-11-13 03:08:06 +01:00
parent e6da7b0b9c
commit d029f9a1ee
3 changed files with 7 additions and 4 deletions
+1 -1
View File
@@ -56,7 +56,7 @@ class Route:
escalated_at: int = 0
def __post_init__(self) -> None:
# Raises on a programming error only, so nothing catches it: route_of checks fits before it builds a route, and todo_table.items gives first_route only levels on their scales.
# Raises on a programming error only, so nothing catches it: a caller builds a route only from levels it checked with fits, or took from an item todo_table.items read, which holds none off its scale.
if not levels_fit(self.item, self.likelihood, self.escape_and_impact, self.escape_and_impact_taken_in):
raise ValueError(f"a route by item {self.item} cannot hold an L of {self.likelihood}, an E + I of {self.escape_and_impact} and an E + I taken in of {self.escape_and_impact_taken_in}")