Repository navigation
fix(land): eject a conflicting PR only once the chain before it lands - #289
Merged
Merged
Conversation
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
…#289) * fix(land): eject a conflicting PR only once the chain before it lands push ejected every PR that conflicted with the chain built before it as merge_conflict, even when that chain did not land in the run: a passing prefix that stopped short of it, a moved head, a withdrawn PR, or a refused push. The PR then lost its place for a conflict with PRs that never reached the base. Now push ejects it only once every PR built before it has landed, which includes a conflict with the base alone, and the comment names the PRs that landed. Otherwise it stays queued, and the next run builds it again without the PRs that did not land. check names what each PR conflicts with. The rechaining after a PR fails alone (#287) already covers the moq-dev/moq queue #6985, #7027, #6999; its test now uses that shape. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
moq-bot
Bot
force-pushed
the
fix/land-rechain
branch
from
October 30, 2026 16:06
5246292 to
33fa0f4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
quest land pushejected every PR that conflicted with the chain built before it asmerge_conflict, even when that chain did not land in the run. The PR then lost its place over a conflict with PRs that never reached the base.moq-dev/quest#287 already rebuilds the chain in the same run after a PR fails alone. That covers the live cases:
Both runs used quest
01d051cf, which predates #287. The same wrong ejection still happened on main whenever the chain before the conflicting PR did not land:This change:
buildrecords, for each conflict, how many links were built before it (after).pushejects a conflicting PR only once every one of those links has landed in this run. With nothing before it, that means a conflict with the base, which is ejected at once. Otherwise the PR stays queued, and the next run builds it again without the PRs that did not land.checklogs what each PR conflicts with (the base, or the PRs before it), and logs it again when that changes after a rebuild.stopper(), so every path reaches the conflict step.The three-phase split is unchanged.
checkandreplaybuild and validate the same chains as before.pushdecides only from the replayed chain and what actually landed, so the outcome is deterministic.--budgetstays coherent: when the budget stops the run after an ejection, nothing lands, so a PR behind the ejected one stays queued. The replayed chain already leaves out the ejected PR, so a PR that conflicted only with it no longer conflicts and also stays queued.There is no stall: whenever a conflicting PR waits, the run either landed or ejected something, or reported a withdrawn PR. In every case
pushprints a line, so the workflow runs again.Test evidence
New and updated tests in
test/land.test.ts:[1,3],[1],[2,3]. chore(deps): bump the nix group with 2 updates #1 is ejectedfailed_checks; feat: name the branches a quest merges through #2 and quest: plan converging MoQ onto standalone Quest #3 land in the same run. This already passed on main via feat(land): keep checking the rest of the queue after an ejection #287 and is now pinned.Against main's
src/cli/land.ts, the two new push-phase tests and the updated conflict test fail. With this change, all 28 land tests pass.just check: passed.just test: passed (626 vitest tests plus the shell, lifecycle, and Worker suites). This session leakedCLAUDE_CONFIG_DIRinto the environment, which broke two unrelatedagent.test.tscases. Re-run with it unset, everything passes.Decisions for review
Review
quest review --base origin/main), gpt-6.1-sol, medium effort, round 1🤖 Generated with Claude Code
(Written by Claude Opus 5.5)