Skip to content

fix: backfill nested pagination#10

Closed
MkDev11 wants to merge 1 commit into
entrius:testfrom
MkDev11:fix/issue-9-backfill-pagination
Closed

fix: backfill nested pagination#10
MkDev11 wants to merge 1 commit into
entrius:testfrom
MkDev11:fix/issue-9-backfill-pagination

Conversation

@MkDev11
Copy link
Copy Markdown
Contributor

@MkDev11 MkDev11 commented May 8, 2026

Summary

Fix backfill pagination for nested GitHub GraphQL connections used by miner scoring inputs.

Root cause: repo backfill paginated parent PR/issue pages, but treated capped nested reviews, labels, and label timelineItems connections as complete. Historical rows could silently miss PR reviews and label events before webhook registration.

Changed behavior:

  • paginate PR reviews beyond the initial nested page
  • paginate PR and issue current labels beyond the initial nested page
  • paginate PR and issue labeled/unlabeled timeline events beyond the initial nested page

Preserved behavior:

  • parent PR/issue backfill pagination and date cutoff behavior are unchanged
  • live webhook ingestion remains unchanged
  • single-page nested responses without nested pageInfo still persist from the initial nodes without extra fetches

Related Issues

Closes #9

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Other (describe below)

Testing

  • npm test
  • npm run format:check
  • npm run lint
  • npm run build
  • git diff --check

Live GitHub API/E2E backfill was not run locally; coverage uses deterministic mocked GraphQL responses for paginated and non-paginated nested connections.

Checklist

  • I have read the Contributing Guide
  • Code builds without errors
  • New and existing tests pass (if applicable)
  • Documentation updated (if applicable)
  • No unnecessary dependencies added

@xiao-xiao-mao xiao-xiao-mao Bot added the bug Something isn't working label May 8, 2026
@MkDev11 MkDev11 marked this pull request as ready for review May 8, 2026 01:38
@MkDev11 MkDev11 changed the title Fix backfill nested pagination fix: backfill nested pagination May 8, 2026
@anderdc
Copy link
Copy Markdown
Collaborator

anderdc commented May 10, 2026

Closing alongside #9 — see issue note. Scope is also disproportionate (+691/-11 for full nested cursor pagination across three connections) relative to the data the mirror scorer actually consumes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Backfill truncates review and label history before miner scoring reads it

2 participants