Conflicting PR reached Human Review: -vN resolution never on PR branch; fast path skips mergeability (#591)
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
Research direction
Start with Flow.stage in flow.py around line 1488 and head_check in promoted.py around line 493, then trace the merge-to-main and reject/resume paths described in the issue. Check how the -vN resolution relates to the PR head and how mergeability is read. Done means conflicting PRs cannot receive a pass or move into Human Review, and staged or reviewed PRs are rechecked when main changes.
Written by the indexing model from the issue text.
Description
What happened
PR tangentcode/platform#591 reached Human Review with a PR branch that conflicts with main. Michal's rule: a PR leaves In Progress only if it merges cleanly onto main.
Timeline (ET, 2026-11-19):
- 11:38 AM: fill found #591 conflicting with the future main in work (#567 ahead of it). Fix-in-place (tangentswarm #146) had the worker resolve it on the speculative branch ptw-captions-come-only-v1 (bacfa612). The PR branch ptw-captions-come-only stayed at 4e36b680, which does not contain the resolution.
- 12:01:49 PM:
stage: #591 4e36b680 is pre-merged: Ready -> Staging, no gate re-run (tangentswarm #136). Flow.stage (flow.py ~1488) also writesapply #591 4e36b680 PASS, the gate pass line the promote fast path reads. At this time main did not have #567 yet, so 4e36b680 was still clean against main. - 12:16:22 PM: #567 merged (6bef7814). 4e36b680 now conflicts with main in 5 files.
- 12:16:27 PM: promoted.fast_path moved #591 Staging -> Human Review "(gate pass at 4e36b680)". head_check (promoted.py ~493) checks only that the head has a gate pass and is not a draft.
- 12:22 PM: Michal saw the conflict in Human Review.
Root cause
The pre-merge model resolves a conflict with future main on the -vN branch, but the PR branch, which is what Michal merges, keeps the unresolved head. Two places then treat the PR head as good:
- Flow.stage writes a gate PASS for the PR head (4e36b680) even when the pre-merged tip in work is a -vN resolution that the PR head lacks. The pass is for the -vN tip, but it is recorded for the PR head.
- The promote fast path (head_check) never checks mergeability against the current main. Nothing rechecks a PR in Staging or Human Review after main moves.
Fix (proposed)
- When fix-in-place resolves a conflict on -vN, the PR is not done until the same resolution is on the PR branch (a normal merge of main into the PR branch once its predecessor merges, or a merge of the -vN resolution into the PR branch). Until then, do not write a gate pass for the PR head; mark it as "needs main merge".
- In head_check, refuse the move when GitHub reports mergeable CONFLICTING / mergeStateStatus DIRTY for the PR (one PR read; UNKNOWN means wait and retry). The merge event that freed the slot is exactly when this must be rechecked.
- On each merge to main, recheck mergeability of every PR in Staging and Human Review; a conflicting one goes back to In Progress with a merge-main relay to its worker, through the normal path.
- The reject path that auto-resumes the worker when a card goes Human Review -> In Progress should carry the reason (here the worker woke with no reason and went looking for a note from Michal).
Recovery done
swarmbot moved #591 Human Review -> In Progress at 12:23 PM ET (server converted it to draft and removed merge-ready) and relayed a merge-main brief to the worker (pane %306): merge origin/main into ptw-captions-come-only, normal merge commit, no force-push, tests through test-slot.
- Dominant language
- Python
- Stars
- 3
- Forks
- 0
- Avg merge
- 5h 57m
- Merged PRs (30d)
- 60
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from tangentcode/tangentswarm
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
tangentcode/tangentswarm#167 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
tangentcode/tangentswarm#161 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
tangentcode/tangentswarm#158 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 55/100
tangentcode/tangentswarm#168 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
tangentcode/tangentswarm#165 ·
Maintainers usually reply within 1 day
All issues in tangentcode/tangentswarm
Similar issues
-
Container fails to start when GitHub Releases is unavailable: uv run re-downloads the tvl wheelOpen
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
trezor/trezor-user-env#421 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 1/5 1-3 hours Newbie friendliness 91/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
hermes hooks doctor smoke test never checks the hook exit code — a crashing hook (exit=1) renders ✓ "ran clean" and "All shell hooks look healthy"Possibly taken @cestercian claimed this today. Opencomp/cli P2 type/bug
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
NousResearch/hermes-agent#162259 · 1 comment ·
Maintainers usually reply within 1 day