Repository navigation
Description
Bug type
Behavior bug (incorrect output/state without crash)
Beta release blocker
No
Summary
On a managed Git install, a Gateway MCP request tries to load DeepSeek's raw TypeScript web-search contract from under node_modules, where Node rejects type stripping, even though the compiled JavaScript artifact is present.
Steps to reproduce
- Run OpenClaw 2026.11.5 (
7db69bedeab6) from the managed Git release layout on Node 24.22.1. - In WebChat, start a turn with Fable 5.2 through the native Claude CLI with the bundled OpenClaw MCP bridge.
- The turn fails before replying. Retrying starts a fresh process but produces the same Gateway log error.
Expected behavior
The Gateway loads the bundled contract and initializes its loopback MCP server so the CLI receives Gateway tools, as described in the CLI backends documentation.
Actual behavior
Both attempts logged a Node type-stripping error for the source file immediately before the MCP startup failure. The compiled contract exists in the same release. No model-version rejection was observed.
OpenClaw version
2026.11.5 (7db69bedeab6)
Operating system
Ubuntu 24.04.4 LTS, Linux 6.17.0, arm64; Node v24.22.1
Install method
Managed Git development install, running from git-install/releases/<release>/lib/node_modules/openclaw.
Model
claude-fable-5-2 (observed trigger; other callers weren't tested)
Provider / routing chain
WebChat → OpenClaw Gateway → native claude-cli → Claude Code 2.1.322 with OpenClaw's loopback MCP bridge.
Logs
Redacted Gateway excerpts (same errors on retry):
warn mcp-loopback request handling failed: Stripping types is currently unsupported for files under node_modules, for "<state-dir>/git-install/releases/<release>/lib/node_modules/openclaw/extensions/deepseek/web-search-contract-api.ts"
error Embedded agent failed before reply: Claude Code started without the OpenClaw MCP server (status failed). The CLI process was retired; retry the request to start a fresh process.
Screenshots, recordings, and evidence
Both paths exist under the running release root:
extensions/deepseek/web-search-contract-api.ts(the path named in the error)dist/extensions/deepseek/web-search-contract-api.js(compiled artifact)
Impact and severity
Blocks the affected WebChat workflow: 2/2 observed attempts failed before a reply on this managed Git installation. Other callers and installations were not tested.
Additional information
- The running build contains feat(update): run Git checkout installs from releases behind the release link #199706, which introduced the managed Git release layout under
node_modulesand notes Node's type-stripping restriction. No pre-change reproduction or last known good build was verified. - [Bug]: claude-cli turn runs without OpenClaw tools when init reports the openclaw MCP server failed #176138 and fix(anthropic): stop reporting success after OpenClaw MCP startup fails #176154 cover how the CLI surfaces an MCP connection failure; this report tracks the Gateway module-load error immediately preceding that failure.
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
clawsweeper commentedon Nov 19, 2026
Codex review: this still needs some work.
Summary
Keep this issue open: the merged layout fix does not resolve recovery when an older updater builds the candidate beneath node_modules; an open maintainer-authored PR addresses that remaining failure.
Reproducibility: The reported legacy layout and maintainer upgrade trace match current main's source-first contract selection; no live reproduction or tests were run during this read-only review.
Next step
Review #200578 for legacy-updater recovery and confirm the original MCP turn succeeds before closing this issue.
Review details
Best possible solution:
Affected legacy installations should update themselves into the corrected release layout and resume contract-loading Gateway requests without manual checkout rebuilding.
Do we have a high-confidence way to reproduce the issue?
The reported legacy layout and maintainer upgrade trace match current main's source-first contract selection; no live reproduction or tests were run during this read-only review.
Is this the best way to solve the issue?
Moving releases outside node_modules repairs newly built layouts, while the open follow-up's compiled-contract selection addresses candidates placed there by older updaters and must preserve ordinary checkout source precedence.
AGENTS.md: found and applied where relevant.
Remaining risk / open question:
Codex review notes: model internal, reasoning medium; reviewed against 76cbbdf70d30.
Label changes
Label changes:
impact:crash-loop: The maintainer-confirmed configured-provider case fails Gateway startup and repeats the failure during update activation.clawsweeper:fix-shape-clear: Current issue advisory state no longer selects this label.clawsweeper:queueable-fix: Current issue advisory state no longer selects this label.impact:other: Current review impact labels areimpact:crash-loop.Label justifications:
P1: Affected managed Git installations can lose Gateway startup and repeatedly roll back updates, blocking an existing agent workflow.impact:crash-loop: The maintainer-confirmed configured-provider case fails Gateway startup and repeats the failure during update activation.Evidence reviewed
What I checked:
src/infra/git-release.ts:39, 76cbbdf70d30)src/plugins/public-surface-runtime.ts:257, 76cbbdf70d30)src/plugins/public-surface-runtime.ts, f511a0a5177c)src/infra/git-release-paths.ts:57, 2ef6f7bade7c)src/infra/update-runner-git-release.test.ts:645, 76cbbdf70d30)How this review workflow works
@clawsweeper re-reviewcomments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.@clawsweeper re-reviewor@clawsweeper re-runon an open PR or issue to request a fresh review only.@clawsweeper reviewto request a fresh review only.@clawsweeper explainto ask for more context, or@clawsweeper stopto stop active automation.Reviewed November 21, 2026, 2:54 AM ET / 07:54 UTC.
obviyus commentedon Nov 19, 2026
Thanks for the precise report. The cause is the Git release layout from #199706.
Each release lived at
git-install/releases/<id>/lib/node_modules/openclaw. The plugin loader forces anything undernode_modules/openclaw/onto Node's native loader. Node refuses to strip types undernode_modules, so the bundledweb-search-contract-api.tssources failed to load. The updater missed it because it built and checked each release beside its final path, then moved it undernode_modules.#201917 moves Git releases to
git-install/releases/<id>/openclaw, behindgit-install/openclaw, and builds and checks each release at that path.This affects dev-channel Git installs on
mainbuilds since 2026-11-17 (they report 2026.11.5). The published 2026.11.5 release still updates Git checkouts in place.Once #201917 lands, could you confirm it on your install?
openclaw update. Your current updater runs this one, so the release still lands undernode_modules.openclaw updateonce more. This one moves the release out.claude-cli.realpath ~/.openclaw/git-install/openclawshould show nonode_modules, and the Gateway log should have no "Stripping types" line. Please reply with whether the turn now replies.fix(update): build and serve Git releases outside node_modules (#201917)
obviyus commentedon Nov 19, 2026
#201917 landed in 2ef6f7b. One correction to my earlier steps, from a real upgrade run that starts at your build
7db69bedeab6:openclawfrom your checkout. Do not start them from the Control UI or another Gateway-started update. The old release cannot run its own updater: it fails with the same "Stripping types" error, forscripts/stage-bundled-plugin-runtime.mts.In that run, the first update moved the checkout to the fix. The second, now run by the fix, rebuilt the release at
git-install/releases/<id>/openclawand removed the old link. The Gateway then started andweb_searchsucceeded, with no stripping error in its log.Please confirm whether your WebChat turn replies after the two updates.
test(update): add a Git release upgrade-survivor scenario (#201956)
fix(update): build and serve Git releases outside node_modules (openc…
test(update): add a Git release upgrade-survivor scenario (openclaw#2…
obviyus commentedon Nov 20, 2026
A correction to my earlier steps. An upgrade test that starts from your build (
7db69bedeab6), with a web search provider configured, found a case where they do not work.That build still runs the update itself, so it builds the fixed version in the old
lib/node_moduleslocation. The new Gateway then hits the same "Stripping types" error at startup, and the update rolls back. Runningopenclaw updateagain repeats this.If that happens to you, update the checkout by hand once, so the fixed updater runs the next update:
The last command now runs the fixed updater. It rebuilds the release at
git-install/releases/<id>/openclawand removes the oldgit-install/lib/node_modules/openclawlink. Afterwards,realpath ~/.openclaw/git-install/openclawshould show nonode_modules.Without a web search provider configured, the Gateway starts normally on the old layout, and the earlier two-update steps work.
fix(plugins): load built public surfaces when a release sits under no…
feat(update): run every Git install from releases and delete the in-p…
proof: openclaw#201874 node_modules public surface A/B
feat(update): run every Git install from releases and delete the in-p…
feat(update): run every Git install from releases and delete the in-p…