Repository navigation
refactor(agents): deduplicate bundle MCP adapters - #113240
Merged
Merged
Conversation
steipete
marked this pull request as ready for review
July 24, 2026 05:47
steipete
force-pushed
the
codex/z-runner-dedup-2
branch
from
July 24, 2026 05:56
59ff437 to
62cc59e
Compare
Contributor
Author
|
Land-ready verification complete for head
Known proof gaps: no live provider call was run because this is deterministic, behavior-neutral config/argument projection; the provider adapters, changed gates, import-cycle guard, and hosted CI cover the changed contract. |
steipete
force-pushed
the
codex/z-runner-dedup-2
branch
from
July 24, 2026 06:00
62cc59e to
6e33a85
Compare
Contributor
Author
|
Merged via squash.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 24, 2026
This was referenced Oct 21, 2026
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.
What Problem This Solves
The CLI and embedded runner families had accumulated parallel bundle-MCP adapter mechanics. A partial shared extraction covered a few scalar fields, but provider adapters still independently applied fresh/resume arguments, materialized temporary JSON, rotated per-attempt capture headers, and normalized the same server fields.
Why This Change Was Made
This completes the extraction with a runner-neutral server projection and one CLI runtime mechanism for argument injection, temporary JSON lifecycle, and capture-header updates. Claude, Codex, and Gemini keep their provider-specific schemas and persistence semantics. The adjacent auth-planning and tool-call-normalization paths were audited but intentionally left separate because their retry, cooldown, transcript-repair, and event-parsing contracts are not identical.
AI-assisted implementation; maintainer-commissioned LOC-reduction batch
codex-z13-runner2.User Impact
No user-visible behavior changes. The same MCP server configuration, auth placeholder handling, capture tokens, CLI arguments, file lifecycle, and provider-specific projections now flow through fewer production paths.
Evidence
+158 / -177across 8 files, net-19; test LOC:+0 / -0.node scripts/crabbox-wrapper.mjs run --provider blacksmith-testbox --timing-json -- env CI=1 OPENCLAW_TESTBOX=1 OPENCLAW_TESTBOX_REMOTE_RUN=1 corepack pnpm test src/agents/cli-runner/bundle-mcp.test.ts src/agents/cli-runner/bundle-mcp.codex.test.ts src/agents/cli-runner/bundle-mcp.gemini.test.ts src/agents/codex-mcp-config.test.ts— 4 files / 23 tests passed on Testboxtbx_01ky9a967bk4kdbvaa0m22f49t(run).node scripts/check-changed.mjs -- src/agents/bundle-mcp-adapter.ts src/agents/cli-runner/bundle-mcp-runtime.ts src/agents/cli-runner/bundle-mcp-claude.ts src/agents/cli-runner/bundle-mcp-codex.ts src/agents/cli-runner/bundle-mcp-gemini.ts src/agents/cli-runner/bundle-mcp.ts src/agents/codex-mcp-config.ts— core/core-test typecheck, lint, formatting, guards, and import-cycle checks passed on Testboxtbx_01ky99z7g25fnstgnve6bh99kk(run)..agents/skills/autoreview/scripts/autoreview --mode uncommitted --stream-engine-output— clean; no accepted/actionable findings, overall correctness 0.94.git diff --check— passed.