Skip to content

fix(poll): suppress Sentry noise for self-healing hot-poll failures - #120

Merged
wgordon17 merged 2 commits into
gordon-code:mainfrom
wgordon17:fix/hot-poll-sentry-noise
Jul 28, 2026
Merged

fix(poll): suppress Sentry noise for self-healing hot-poll failures#120
wgordon17 merged 2 commits into
gordon-code:mainfrom
wgordon17:fix/hot-poll-sentry-noise

Conversation

@wgordon17

Copy link
Copy Markdown
Member

Summary

  • Hot-poll fetch errors (e.g. transient TypeError: Failed to fetch against api.github.com) were reported to Sentry on every occurrence, even though retry/backoff already recovers within a cycle or two
  • fetchHotData()/fetchHotPRStatus() now only capture to Sentry once consecutive failures cross a threshold (3), while keeping the existing console.warn/toast feedback for transient blips

Hot-poll fetch errors were reported to Sentry on every occurrence, even
though retry/backoff already recovers from isolated network blips
(e.g. TypeError: Failed to fetch) within a cycle or two.

fetchHotData() and fetchHotPRStatus() now only capture to Sentry once
consecutive failures cross HOT_POLL_SENTRY_THRESHOLD (3), keeping the
existing console.warn/toast feedback for transient failures.
Adds coverage for the gating logic added in the prior commit:
- fetchHotPRStatus respects the reportToSentry option (default off)
- fetchHotData only reports once priorConsecutiveFailures reaches
  HOT_POLL_SENTRY_THRESHOLD, for both the PR-status and workflow-run
  fetch paths
- End-to-end coordinator test drives 4 real failing cycles through
  fake timers, confirming consecutiveFailures actually threads from
  createHotPollCoordinator into fetchHotData across cycles and only
  the 4th (post-threshold) failure reports to Sentry
@wgordon17
wgordon17 marked this pull request as ready for review July 28, 2026 19:12
@wgordon17
wgordon17 merged commit c2ddb34 into gordon-code:main Jul 28, 2026
1 check passed
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