From 50c029c04488e1d5da8faf9f152c527f61d2c003 Mon Sep 17 00:00:00 2001 From: rcourtman Date: Sun, 21 Dec 2025 23:31:21 +0000 Subject: [PATCH] fix: exclude watch from patrol status summary Since watch/info findings are filtered from the UI and never shown to users, don't include them in the patrol run status summary. This makes the summary consistent with what users actually see. --- internal/ai/patrol.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/internal/ai/patrol.go b/internal/ai/patrol.go index 911d917..beca147 100644 --- a/internal/ai/patrol.go +++ b/internal/ai/patrol.go @@ -872,7 +872,8 @@ func (p *PatrolService) runPatrol(ctx context.Context) { summary := p.findings.GetSummary() var findingsSummaryStr string var status string - totalActive := summary.Critical + summary.Warning + summary.Watch + // Only count critical and warning as active issues (watch/info are filtered from UI) + totalActive := summary.Critical + summary.Warning if totalActive == 0 { findingsSummaryStr = "All healthy" status = "healthy" @@ -884,9 +885,6 @@ func (p *PatrolService) runPatrol(ctx context.Context) { if summary.Warning > 0 { parts = append(parts, fmt.Sprintf("%d warning", summary.Warning)) } - if summary.Watch > 0 { - parts = append(parts, fmt.Sprintf("%d watch", summary.Watch)) - } findingsSummaryStr = fmt.Sprintf("%s", joinParts(parts)) if summary.Critical > 0 { status = "critical"