From c655586202b86e50fc0b92504a0ee7ec8f89ea20 Mon Sep 17 00:00:00 2001 From: Sulthan Zaki Date: Sun, 23 Aug 2026 02:48:14 +0700 Subject: [PATCH] #172: clear the empty-Site suppression row only for sidecar-down Only sidecar-down ever writes a Site=='' row, so the loop's empty-Site clear for the other three conditions was a no-op delete on every pass. Move it out of the per-condition loop, scoped to ConditionSidecarDown. --- backend/internal/latest/poller.go | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/backend/internal/latest/poller.go b/backend/internal/latest/poller.go index d6da47a..088ae49 100644 --- a/backend/internal/latest/poller.go +++ b/backend/internal/latest/poller.go @@ -647,12 +647,13 @@ func (p *Poller) ownerNotices(ctx context.Context, row store.LanePass) { log.Printf("latest poll %s: clear owner notice: %v", row.Site, err) } } - // The site-wide conditions suppress under the empty Site; clear that - // row too, so a lifted sidecar-down fires again when it returns. - if !hasFault(faults, cond, "") { - if err := p.Store.ClearNotice(cond, ""); err != nil { - log.Printf("latest poll %s: clear owner notice: %v", row.Site, err) - } + } + // sidecar-down suppresses under the empty Site — one row across all + // browser Lanes (AC4) — so clear that row when it is absent from this + // pass's fault list, and a lifted sidecar fires again when it returns. + if !hasFault(faults, ConditionSidecarDown, "") { + if err := p.Store.ClearNotice(ConditionSidecarDown, ""); err != nil { + log.Printf("latest poll %s: clear owner notice: %v", row.Site, err) } } }