Summary
fix(threshold): off-by-one in burn-rate window aggregation — addresses the regression surfaced in thresholdctl after the recent fix work landed on main.
Why
- The previous behavior on
mainshort-circuited the safe path under load; this PR restores the intended contract. - Adds a guard so the regression cannot resurface silently in staging.
- Drive-by: removes dead-code call sites the linter was warning about.
Scope
- Files touched: 5 across the core module + tests.
- No public API change; ABI is preserved.
- CI: all green on the matrix runs.
Labels: bug