Run the merge head race through the real gateway and github-mcp-server - #242
Open
arpanghoshal wants to merge 4 commits into
Open
arpanghoshal wants to merge 4 commits into
arpanghoshal wants to merge 4 commits into
Conversation
A reader of github/github-mcp-server#3230 ran the PR-merge head race against Control.execute with a fake provider and asked which row changes through the gateway. This runs it through the real stack: ctrlrun gateway in front of github-mcp-server 1.14.0 in http mode, in front of a fake GitHub REST API that keeps the merge endpoint's sha semantics. Eleven scenarios, three of them with no gateway as the control. Through the gateway an approved merge without expectedHeadSha lands at a head nobody approved, because the gateway has no precondition recheck. With it, GitHub refuses the stale merge and the SHA is bound into the approval. The run also records three gaps: a GitHub 409 and a lost reply are indistinguishable to the gateway, not_executed_on_error is false for this server, and requiring an argument only works through the absent-argument fallback. A fourth: the gateway's pre-check refusals leave no receipt and no event. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Arpan Ghoshal <contact@arpanghoshal.com>
Written by ctrlrun-docs tools/docs_audit/render_cookbook.py from docs/cookbook/github-merge-agent.mdx. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Arpan Ghoshal <contact@arpanghoshal.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 29 minutes. View limit detailsLimit details: You’ve used the included review currently available. Review configuration: ⚙️ Run configuration
📒 Files selected for processing (8)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Arpan Ghoshal <contact@arpanghoshal.com>
…erals CodeQL reads an implicit string concatenation inside a list as a missing comma. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Arpan Ghoshal <contact@arpanghoshal.com>
This branch has not been deployed
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.
A reader of github/github-mcp-server#3230 ran the PR-merge head race against
Control.executewith a fake provider and asked which row changes through the gateway.research/github-merge-head-race/answers that through the real stack:ctrlrun gateway→ github-mcp-server 1.14.0 (http) → a fake GitHub REST API that keeps the merge endpoint'sshasemantics. Eleven scenarios, three with no gateway as the control. Results are fromctrlrun[gateway]==0.12.2off PyPI and matchmainat1c02d1e.What it found:
expectedHeadSha, an approved merge lands at a head nobody approved. The gateway has no precondition recheck (SPEC-v0.7 §6.4).409and a dropped connection the same way (isError+ text), so the gateway records bothambiguous.mcp: {not_executed_on_error: true}is false for this server: it recordedfailedfor a merge that landed.expectedHeadShaworks only through the absent-argument fallback: Gateway: an absent argument is not a typo, so let a policy require one #239.The second commit is the
github-merge-agentrecipe, extracted from CTRLRun/ctrlrun-docs byrender_cookbook.py; its page is in the companion docs PR.Tests:
test_cookbook.py,test_examples.py,test_repository_signals.pyandtest_packaging.pypass (273). The full suite locally has 14 failures, none from this change: 12 intest_hop.py, fixed by #241, and 2T221connect-timeout tests that only fail on macOS 27, fixed onmacos-27-full-backlog-rst. Merge #241 first, or this PR's CI goes red on the hop tests.🤖 Generated with Claude Code