You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 8d4021c
Browse filesBrowse the repository at this point in the historyBrowse files
Detect flaky checks across a form's full recorded history
Feature 2 of 4 requested large improvements. history::diff only ever
compares two adjacent runs, so it can't distinguish "this check
regressed and stayed broken" (worth investigating the one real change)
from "this check has been flip-flopping for weeks" (worth investigating
why it's unstable before trusting any single run's verdict at all) —
both just look like "it changed" to diff.
Added history::flakiness(runs): for each check present in the most
recent run, counts how many times its status differed from the run
right before it across the *entire* recorded history for that form.
2+ transitions is flagged flaky; 0 or 1 is a stable check or a single
genuine regression/fix, not flakiness.
Wired into report::build via a new FormReport.flaky field and a
flakiness_of(check) lookup method, surfaced as a "⚠ Flaky" badge in
--html and a "[FLAKY]" note in plain text (both `formwatch report` and
`formwatch test`/`monitor`'s own per-run printing, which computes it
from the same history::load_runs call they already make).
Verified the >=2 threshold is real by temporarily changing it to >=1
and watching the "single sustained regression is not flakiness" test
fail exactly as predicted, then restoring it. Separately verified
report::build's wiring (not just flakiness()'s own logic, already
covered directly in history.rs) with a dedicated test building three
runs — one check flip-flops, one has a single sustained change — and
confirming report::build only flags the former; verified that test too
by loosening flakiness_of's filter and watching it catch the resulting
false positive.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
0 commit comments