Direct answer
A merge queue validates a combination of pull requests, not one pull request at a time. When a group fails, the useful question is which member broke the combination. Check that continuous integration triggers on the merge-group event, read the failed group’s composition, find the member whose change caused the failure, fix that cause, and let the queue rebuild the affected set. Do not bypass required checks to clear the line.
Claude Code can help read the failure and draft the fix. It does not configure GitHub for you, and it cannot make a failing group pass. The recovery is a diagnosis task with a human decision about the fix.
Why a failed group is not a failed pull request
A merge queue groups several pull requests together and runs checks against the branch as it would look with all of them merged. The group passes or fails as a unit. A green check on each pull request individually does not guarantee the combination is green, because interactions between changes only appear when they share a base.
That design is the point. The queue catches breakage that per-pull-request checks miss. The cost is that a failure needs a second step of diagnosis: separate the bad member from the bad combination.
The expensive mistake is treating a group failure as a random flake and rerunning it. If one member has a real defect, every group containing that member fails the same way. Reruns burn continuous integration minutes and delay every pull request behind the failing one.
Confirm the queue is enabled
Merge queues are a repository setting, not a universal feature. Confirm the target branch actually has one before diagnosing, because the symptoms differ: a branch without a queue shows failures on individual pull requests, while a branch with a queue shows failures on merge-group runs.
Official, F067: GitHub documents that merge-queue continuous integration must trigger on merge_group events or on the queue’s branch prefixes. The exact workflow configuration belongs to the repository.
Availability depends on repository ownership and plan, so a queue that exists in one repository may not be available in another. Check the branch settings rather than assuming.
| Queue group | Member pull requests | Failed check | Suspected owner |
|---|---|---|---|
| Group 418 | 3 members | Integration suite on merge-group run | Member 2, database migration |
| Group 419 | 2 members | Type check on merge-group run | Member 1, shared type change |
| Group 420 | 4 members | Build on merge-group run | Queue configuration |
| Group 421 | 3 members | Flaky test, passes on retry | Test owner |
The last row is the exception that proves the rule. A check that passes on retry and fails across unrelated members is a flake, not a bad member. Treat it as a test problem, not a pull request problem.
Check the merge_group trigger
The queue cannot validate a combination if continuous integration never runs on the combination. A workflow that only triggers on pull request events will pass each member in isolation and never test the group.
Official, F067: The merge_group event documentation identifies the trigger that merge-queue runs use. A workflow that omits it will not produce a meaningful group result.
Two symptoms point at a missing trigger. The group fails with no checks having run, or the group passes using results carried over from the individual pull requests. Both mean the combination was never actually validated.
Ask Claude Code to read the workflow files and report which triggers each workflow responds to. The agent can list the on-block of each file quickly. Verify the answer against the workflow editor in the repository settings, because the agent reads the files as they are and the effective configuration can include repository-level defaults.
| Trigger event | CI result | Rebuild result | Remaining blocker |
|---|---|---|---|
| pull_request only | No group run | Queue cannot validate | Add the merge_group trigger |
| merge_group present | Group runs | Rebuild after fix works | Fix the failing member |
| merge_group with path filter | Some groups skipped | Skipped groups unvalidated | Review the filter |
| Required check not reported | Group blocked | No rebuild | Fix the check reporting |
Read the failed group composition
The failure page lists the members of the group and the check that failed. Read both. The composition tells you which changes were being validated together, and the failing check tells you where the interaction broke.
A group that fails on an integration test with four members has a different diagnosis than a group that fails on a type check with two. Integration tests usually point at a behavioral interaction between members. Type and build failures usually point at one member that conflicts with the shared base.
Claude Code is useful here as a reader. Give it the member list and the failing test name, and ask which members touch the code the test exercises. The answer narrows the suspects from all members to the ones plausibly responsible.
Identify the failing pull request
Narrowing usually works by removal. If one member reverts cleanly and the remaining combination passes, that member is the cause. The queue rebuild after removing a member is itself evidence.
Look for the member whose change is newest or least reviewed when the evidence is ambiguous, but let the failure mode lead. A database migration in the group points at the migration. A shared-type rename points at the rename. The failing check names the subsystem.
| Recovery action | Check status before | Check status after | Follow-up |
|---|---|---|---|
| Remove the suspect member | Group red | Group green without it | Fix and re-add |
| Fix the failing test | Group red | Group green | Confirm on the rebuilt group |
| Add the missing trigger | No group run | Group runs | Review prior skipped groups |
| Rerun without a fix | Group red | Group red | Stop rerunning; diagnose |
The suspect member is a hypothesis until the rebuild confirms it. Removing it and seeing the group pass is the confirmation. Without that step, you are guessing, and a guess that names the wrong member delays the whole queue.
Fix the cause without bypassing checks
The fix belongs in the pull request that caused the failure, not in a workaround that lets the group pass. Bypassing a required check to clear the queue defeats the mechanism that caught the problem.
Official, F068: GitHub documents that a failed group removes the specific failing pull request and rebuilds subsequent groups. Behavior can depend on queue settings such as how non-failing pull requests are handled.
The removal-and-rebuild behavior is the queue working as designed. The failing member leaves the group, the others proceed, and the failing member re-enters after a fix. Let that happen rather than fighting it.
A fix in the failing pull request should include the check that caught the problem. If the interaction was only visible in the group run, the pull request’s own checks may still be green after the fix. That is expected, and the group rebuild is the confirmation that matters.
Let the queue rebuild affected groups
After the fix lands, the queue rebuilds the affected groups. That rebuild is the validation you want, so let it run rather than trying to shortcut it.
The rebuild can take longer than a single pull request check because it validates a combination again. Wait for it. Retrying the old failed group manually adds noise without adding information, because the queue has already moved the members into new groups.
Ask Claude Code to summarize the rebuild result when it arrives: which members are in the new group, which checks ran, and whether the group is green. The summary is a starting point for the next decision, not a substitute for reading the run.
Avoid queue jumping as a default
Queue jumping, where available, moves a pull request ahead of others in the line. Used sparingly for a genuine urgent fix, it is a tool. Used as a habit, it reintroduces the ordering problem the queue exists to solve.
The harm is not only fairness. A jumped pull request skips the combination validation with the members it overtook, which is exactly the validation that catches interactions. A jump that lands a change without that validation can produce the failure the queue would have caught.
Treat a jump as an exception with a reason recorded. “Hotfix for an active outage” is a reason. “My pull request has been waiting” is a queue-management problem, and the fix is more capacity or fewer simultaneous merges, not a jump.
| Situation | Jump justified | Alternative |
|---|---|---|
| Active outage, fix verified | Yes, with incident reference | Direct hotfix path if one exists |
| Waiting behind several groups | No | Let the queue order itself |
| Jumping to skip a known-slow check | No | Fix the check duration |
| Security fix with a deadline | Case by case | Coordinate with the release owner |
Record the recovery evidence
A queue failure that gets fixed and forgotten will happen again. Record what failed, which member caused it, and what the fix was. The pull request that was removed and re-added is the natural home for that record.
The record also helps the next diagnosis. A team that can see that the last three group failures were integration tests between unrelated features has a signal about test coverage at the seams.
Worked example: four pull requests and a failing integration test
Suppose a group contains four pull requests: a database migration, a shared-type rename, a retry feature, and a documentation change. The group’s integration suite fails on a test that exercises the retry path against a migrated schema.
The composition has four members. The failing check is an integration test, which points at a behavioral interaction rather than a build problem. Two members are plausible: the migration, because the test reads the schema, and the retry feature, because the test exercises the retry path.
Removing the retry feature from the group and rebuilding passes. That is the confirmation. The retry feature’s migration to the new schema was incomplete, and the individual pull request checks did not cover it because they ran against the old schema.
Derived arithmetic for the diagnosis: The group had 4 members and 1 failing integration test. Removal testing narrowed 4 suspects to 1 in a single rebuild. Checks that would have caught the defect per-pull-request: 0, because the defect required the new schema. Required group runs to confirm: 2, the failing run and the rebuild without the suspect. This arithmetic tracks the diagnosis; it is not a benchmark of queue throughput.
The concrete win is that the queue caught an interaction no individual check could see, and the recovery identified the responsible member in one rebuild. The concrete loss is that every pull request behind the failing group waited for the diagnosis, and the fix required schema knowledge that the individual pull request checks did not force.
Practical checklist and runbook
- Confirm the queue is enabled on the target branch before diagnosing.
- Check that workflows trigger on the merge-group event, not only on pull requests.
- Read the failed group’s member list and the name of the failing check.
- Narrow the suspects by asking which members touch the code the check exercises.
- Confirm by removal: rebuild without the suspect and compare.
- Fix the cause in the failing pull request, including the check that caught it.
- Let the queue rebuild the affected groups rather than rerunning the old group.
- Record what failed, which member caused it, and the fix in the pull request.
- Reserve queue jumping for recorded exceptions with a reason.
- Never bypass a required check to clear the line.
| Recovery action | Check status | Queue order effect | Owner |
|---|---|---|---|
| Fix and re-add the member | Green on rebuild | Member re-enters the line | Pull request author |
| Add a missing trigger | Group runs | Prior groups need review | Platform owner |
| Mark a flaky test | Passes on retry | No member change | Test owner |
| Bypass a required check | Group forced green | Validation skipped | Not recommended |
Concrete win, honest loss, and practical implication
Win: The queue failure is diagnosed to one member with a single removal rebuild, the fix lands in the responsible pull request, and the group validates the corrected combination. Required checks stay intact throughout.
Loss: Every pull request queued behind the failing group waits for the diagnosis. The queue buys interaction coverage at the cost of head-of-line blocking when something fails, and the recovery time is bounded by how quickly the failing member can be identified and fixed.
Implication: Keep individual pull requests small and focused so that a group failure has fewer suspects. A group of four focused changes is diagnosable in one rebuild. A group containing four mixed-purpose pull requests can take much longer.
Where this connects in the batch
The settings that decide what the queue requires are covered in defining merge checks with branch protection. The integration method that gets a pull request into the queue is covered in choosing merge or rebase from the branch policy.
The fix that lands after a diagnosis should be a unit on its own. Making changes revertible with atomic commits covers that structure, and encoding change intent in commit messages covers the message that records the fix.
When the interaction that failed was between a change and a schema migration, database migration safety covers that class of risk directly. Resolving merge conflicts by behavior covers the case where the interaction appears as a conflict rather than a test failure.
Adjacent reading includes verification done proof for why a green check on an individual pull request is weaker evidence than a group run, and false success from passing tests for the general trap of green checks hiding a behavioral miss.
Related reading across the batch and the library
The six posts in this batch form one sequence. Defining merge checks with branch protection covers the required checks a queue validates. Choosing merge or rebase from the branch policy covers how a branch reaches the queue. Resolving merge conflicts by behavior covers a related failure that appears earlier. Making changes revertible with atomic commits covers the unit structure that makes a fix isolated. Encoding change intent in commit messages covers the record the fix leaves.
Release and recovery topics continue in choosing a version impact with SemVer, annotated release tags, hotfix backports and cherry-picks, planning a rollback with revert, preparing a changelog from consumer-visible changes, and running a release checklist. The wider testing and debugging lane starts at selecting tests for changed code, triaging flaky tests, and hunting regressions with git bisect.
Adjacent library posts on checks and interactions include database migration safety, false success from passing tests, verification done proof, generated tests and oracle bias, GitHub Actions secrets, repository hooks security, the code review bottleneck, and outages, status, and failover. Estimating monthly LLM API cost covers the spend side of long continuous integration diagnosis sessions.
Data gap and future update
The fact pack contains no measured queue throughput, no benchmark for recovery time, and no reproducible community study of group failure rates. No such figure is claimed here.
The official evidence covers the merge-group trigger requirement and the removal-and-rebuild behavior on failure. It does not quantify how often a group fails or how long recovery takes. Queue availability and behavior also depend on repository settings and plan, so a specific repository may differ from the documented default.
Recheck the cited GitHub pages before relying on specific queue settings, because the available options change across plans. Until stronger evidence exists, treat the recovery runbook as a diagnosis discipline rather than a guaranteed procedure.
One AI API Key option for OpenAI-format agents
Claude Code uses an Anthropic-format route, so the One AI free model IDs are not a Claude Code model source. The research packet records Claude IDs as unavailable on 2026-11-27.
For a separate OpenAI-format agent, One AI API Key offers https://api.oneaiapikey.com/v1, one key, and 46 live free IDs. That option concerns a different client and request format, not a workaround for Claude Code authentication. Review the free model list and eligibility details before choosing an agent route, or start from the quickstart.
FAQ
Does a green check on my pull request mean the group will pass?
No. Individual checks run against the branch without the other members. The group run validates the combination, which is where interactions appear. Both are needed.
Can Claude Code configure the merge queue for my repository?
No. Claude Code can read workflow files and suggest changes, but repository settings are configured by someone with administrative access. The agent does not change GitHub settings by itself.
The group failed but passed on rerun. Was it a flake?
Possibly. A group that passes on retry without any change is usually a flaky test rather than a bad member. Record it as a test problem and fix the test, because a flaky check in a queue failure is expensive to diagnose repeatedly.
Why not just bypass the check to unblock the team?
Bypassing removes the validation that caught the problem. The queue exists to catch interactions that individual checks miss, so a bypass trades a delay for a possible production failure. Fix the cause or remove the failing member instead.
What should I do while the queue is blocked?
Diagnose rather than rerun. Read the failing check, list the members that touch that subsystem, and propose a removal rebuild. Rerunning without a change repeats the same failure and delays everyone behind the group.
More Claude Code troubleshooting
- Claude Code Deterministic Tests: Control Time and Randomness
- Claude Code Contract Tests: Check API Expectations
- Claude Code Snapshot Review: Inspect the Diff, Not the Green
- Claude Code Property Tests: Generate Edge Cases
- Claude Code Mutation Testing: Find Weak Assertions
- Claude Code Test Fixtures: Isolate Shared State
- Claude Code Minimal Repro: Shrink the Failure
- Claude Code Debug Log: Separate Facts from Hypotheses
- Claude Code Async Races: Make Scheduling Deterministic
- Claude Code Memory Leaks: Compare Allocation Snapshots
- Claude Code Complexity: Refactor Hotspots, Not Metrics
- Claude Code Duplication: Choose Reuse or Independence
- Claude Code Static Analysis: Baseline the Noise
- Claude Code Dead Code: Prove Usage Before Removal
- Claude Code Git Stash: Recover Work Without Dropping It
Sources
- Official: GitHub merge queues, documenting the trigger requirement and removal-and-rebuild behavior (F067, F068).
- Official: GitHub merge_group event, documenting the trigger merge-queue runs use.
- Official: GitHub merge with a queue, documenting the contributor-facing flow.
- Official: GitHub branch protection rules, documenting the required checks a queue relies on.
- Official: Claude Code best practices, supporting check-driven work and focused diagnosis.
- Official: Jest configuration, referenced for test configuration that affects group runs.
- Derived: F069 supports inspecting the failed group and fixing the cause before allowing a rebuild.