Skip to content

fix: use last:50 instead of first:50 for solver cross-reference lookup (#1017) - #1126

Closed
alpurkan17 wants to merge 2 commits into
entrius:testfrom
alpurkan17:fix/1017-solver-lookup-last-50
Closed

fix: use last:50 instead of first:50 for solver cross-reference lookup (#1017)#1126
alpurkan17 wants to merge 2 commits into
entrius:testfrom
alpurkan17:fix/1017-solver-lookup-last-50

Conversation

@alpurkan17

@alpurkan17 alpurkan17 commented May 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Change first:50 to last:50 in GraphQL query for solver repository lookup
  • This returns the most recent 50 PRs, where the solver's active PRs live

Root Cause

Solver cross-reference lookup uses first:50 to fetch PRs, which returns the OLDEST PRs first. The solver's most recent PR (the one affecting current scoring) is likely at the end of the list — often beyond the 50-item window, so it's missed entirely.

Impact

Solver cross-reference resolution misses recent PRs, leading to stale solver data and incorrect scoring of solver contributions.

Why

Solvers are scored on recent PRs. first:50 returns oldest PRs — wrong direction for relevance

Related Issues

Fixes #1017

Test plan

  • ruff check
  • ruff format --check
  • pyright
  • pytest tests/utils/test_solver_lookup.py::test_solver_lookup_last_50 -q

How to verify

  1. Run the solver lookup test to confirm last:50 returns recent PRs
  2. Verify the GraphQL query uses last:50 not first:50

Edge cases considered

  • Solver repository has <50 PRs total (last:50 works same as first:50)
  • Repository with only old PRs and no recent activity
  • Private solver repositories (additional auth needed)

Post-merge verification

  • Check solver cross-reference now finds recent PRs correctly
  • Verify solver scoring improved for active solvers

@xiao-xiao-mao xiao-xiao-mao Bot added the bug Something isn't working label May 9, 2026
@anderdc

anderdc commented May 9, 2026

Copy link
Copy Markdown
Collaborator

Duplicate of #1018 which is better scoped/implemented. Closing.

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] Issue-bounty solver lookup uses first: 50 chrono-ASC; popular issues miss the solver PR and the validator votes cancel

2 participants