mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-10-04 21:26:22 +00:00
e69633daf8
BuildBackupVerificationStaleFinding inspects a ProtectionRollup, and when VerifyIntent is "stale" returns a backup-category Finding compatible with the existing patrol intake (FindingsStore.Add / PatrolService.recordFinding). Dedup keys go through the same generateFindingID helper the LLM "case backup:" branch uses, so a stale-still-stale tick updates rather than duplicates. Severity is Watch by default and escalates to Warning once the last successful backup is itself older than twice the staleness window — the MVP's "multiple consecutive stale windows" heuristic without a separate historical counter. Tests cover: emission for a stale rollup; nil for verified / unknown / nil rollups; severity escalation across multiple windows; dedup in the FindingsStore across two patrol ticks; and the resolution path (Resolve(auto=true) + auto_resolved lifecycle event) once verification reappears.