feat(reporter): count heals the gate suppresses
CI / Unit tests (push) Successful in 4s
CI / Unit tests (pull_request) Successful in 3s

A drift whose fingerprint matches a heal from the last heal_min_interval
seconds was counted as a drift event but never as a heal attempt, so the
24h counters showed a drift with no heal and no failure. Decide on the
heal before recording the check and report heals_suppressed_24h and
heals_suppressed_total, so every drift event is either a heal attempt
or a suppressed heal. The suppression warning now names the earlier
heal that did not hold.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
patrickandClaude Opus 5.5 committed 2026-10-19 18:04:24 -04:00
1 parent 02ca338eb7
commit 4e8a4d6717
5 files changed
+50 -11

No files matched your search

+3 -1
View File
@@ -77,7 +77,9 @@ def should_heal(history_file, drift_fingerprint, min_interval=900):
if datetime.now(timezone.utc) - last_time < timedelta(seconds=min_interval):
if last_fingerprint and last_fingerprint == drift_fingerprint:
logging.warning(
"Heal suppressed (recent identical drift fingerprint)."
"Heal suppressed (recent identical drift fingerprint): "
f"the heal at {last_time.isoformat()} did not hold "
f"(fingerprint={drift_fingerprint})."
)
return False