Skip to content

fix(pulls): re-read a lazily unknown mergeability once - #149

Merged
wstein merged 4 commits into
mainfrom
fix/pulls-reread-unknown-mergeable
Oct 22, 2026
Merged

wstein merged 4 commits into
mainfrom
fix/pulls-reread-unknown-mergeable

Conversation

@wstein

@wstein wstein commented Oct 22, 2026

Copy link
Copy Markdown
Owner

Summary

GitHub computes pull request mergeability lazily: the first pulls/N read often returns mergeable: null / unknown, so a green, mergeable PR was reported blocked (unknown) and a single run under-reported ready PRs (observed on wstein/regrip#25-29: first run 3 blocked, second run 5 ready).

  • after the main pass, a PR with green head checks, not draft, same head and null/unknown mergeability is re-read ONCE (pulls/N only), at the end so the other reads gave GitHub time; no sleep, no loop, no second re-read
  • re-reads do not consume --limit; none after a rate-limit stop; a failed re-read keeps the row blocked/unknown and is reported as an error (exit 1)
  • contract, spec, docs/pulls.md and CLI help amended; no schema change

Blocker

Draft until the independent Opus review of the exact head is CLEAR and CI is green.

🤖 Generated with Claude Code

wstein and others added 4 commits October 22, 2026 18:26
GitHub computes mergeability lazily, so the first pulls/N read often
returns mergeable null or state unknown for a mergeable pull request.
After the main pass, re-read such green non-draft rows once (pulls/N
only, no sleep, no loop, outside the --limit budget, never after a
rate limit) and judge the verdict on the re-read.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
… trigger

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@wstein
wstein marked this pull request as ready for review October 22, 2026 18:49
@wstein
wstein merged commit 194429a into main Oct 22, 2026
17 checks passed
@wstein
wstein deleted the fix/pulls-reread-unknown-mergeable branch October 22, 2026 18:54
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