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
bug(platform): Chat Health hides a failed guardrail metrics read as an empty section #3872
Scope: isolated local jsdom/Vitest component probe; no production network or writes.
Reproduction
Render ChatHealthMetricsPage with a valid chat-health response containing 25 turns and a guardrail query that settles with data: undefined, isLoading: false, and a 503 error. The actual page renders the healthy chat cards and title, but the Guardrail events card is zero and the guardrail breakdown has no entries. There is no alert, error copy, or Retry action. The replay probe passed one test against source SHA 9ea59724df24d62729a9360f3902d964dab39b3e and confirmed the guardrail rows Detected and PII disappear while the rest of the page remains normal.
Root cause and impact
ChatHealthMetricsPage consumes error for chat/messages:getOrgChatHealth but destructures only data and isLoading for chat_filter_events/queries:getGuardrailStats. The view intentionally defaults guardrails?.byKind, guardrails?.byFilter, and the event total to empty arrays/zero, so a rejected guardrail read is deliberately degraded into an empty section. The comment describes this as a graceful hiccup, but it makes missing security telemetry indistinguishable from no guardrail activity and gives operators no way to retry the failed read.
Expected behavior is an explicit partial-error state for the guardrail section with Retry, while retaining the successfully loaded chat-health metrics. This is distinct from a full chat-health query failure and from a successful period with zero guardrail events.
Activity