Skip to content

Preserve provider causes in catalog error alerts - #1749

Merged
kevmo314 merged 1 commit into
mainfrom
fix/catalog-provider-error-context
Oct 30, 2026
Merged

kevmo314 merged 1 commit into
mainfrom
fix/catalog-provider-error-context

Conversation

@kevmo314

Copy link
Copy Markdown
Contributor

Two authenticated /getEmotes requests returned 503 at 2026-10-29 15:02 UTC, triggering the latest Agent issues alert. Catalog handling replaced the underlying failure with provider temporarily unavailable, so the recorded errors cannot identify whether Twitch or token lookup failed.

Preserve the redacted provider cause and operation in the logged error chain, including malformed emote responses and safety limits. Client responses retain the same generic callable status and message; error alerts remain enabled. Tokens, request query strings, and provider response bodies are not added to logs. This improves diagnosis of future failures; it cannot recover the discarded cause of the existing incident.

Validation:

  • Regression tests reproduce the missing log context before the fix and verify HTTP status, malformed JSON, transport, missing-user, and token-store failures afterward.
  • Tests verify generic client responses, preserved error types/causes, and no credential or provider-body leakage.
  • CI=true TWITCH_CLI=/tmp/rtchat-twitch-cli/twitch go test -race ./... passes with the CI-pinned Twitch CLI 1.1.24; live YouTube tests are skipped as in CI.
  • go vet ./..., gofmt checks, and the monitoring unit tests pass.

@kevmo314
kevmo314 merged commit dc5ff5c into main Oct 30, 2026
8 checks passed
@kevmo314
kevmo314 deleted the fix/catalog-provider-error-context branch October 30, 2026 03:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant