Skip to content

fix(dashboard): preserve last-known PR enrichment when backfill fails - #140

Merged
wgordon17 merged 2 commits into
gordon-code:mainfrom
wgordon17:fix/pr-enrichment-fallback
Aug 26, 2026
Merged

fix(dashboard): preserve last-known PR enrichment when backfill fails#140
wgordon17 merged 2 commits into
gordon-code:mainfrom
wgordon17:fix/pr-enrichment-fallback

Conversation

@wgordon17

Copy link
Copy Markdown
Member

Summary

  • Poll cycles fully replaced the PR list each cycle, so a transient enrichment-backfill failure wiped size/check-status data and reclassified dependency PRs from Mergeable to Needs Action until the next successful poll.
  • Carry forward a PR's prior enriched fields when the current cycle fails to re-enrich it (both the full-replace and fine-grained merge paths).
  • Add warn + Sentry telemetry to the backfill catch block to match its sibling fetchers.

@wgordon17
wgordon17 marked this pull request as ready for review August 26, 2026 19:47
@wgordon17
wgordon17 requested a review from a team August 26, 2026 19:47
Poll cycles fully replaced the PR list each cycle, so a transient
enrichment-backfill failure (network blocker, blip, or GitHub hiccup)
wiped size/check-status data and reclassified dependency PRs from
Mergeable to Needs Action until the next successful poll.

Add fallbackToPreviousEnrichment to carry forward a PR's prior enriched
fields when the current cycle failed to re-enrich it, and guard the
fine-grained merge path against the same regression. Add warn + Sentry
telemetry to the backfill catch block to match its sibling fetchers.
Extracts pickEnrichmentFields so mergeEnrichment, fallbackToPreviousEnrichment, and the DashboardPage fine-grained merge share one field list, removing the drift risk that a future enrichment field is added to some copy sites but not others.

Adds unit tests covering fallbackToPreviousEnrichment (empty-previous, already-enriched passthrough, missing/unenriched prev, carry-forward, closed-PR drop) and pickEnrichmentFields field selection.
@wgordon17
wgordon17 force-pushed the fix/pr-enrichment-fallback branch from c99db31 to f901a00 Compare August 26, 2026 19:47
@wgordon17
wgordon17 merged commit bc93452 into gordon-code:main Aug 26, 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