Bug
Fresh npm install -g openclaw@latest crashes on startup with missing module errors:
Cannot find module '@buape/carbon'
Require stack:
- /usr/local/lib/node_modules/openclaw/dist/ui-7MjYF8PY.js
After manually installing @buape/carbon, a second missing module appears:
Cannot find module '@larksuiteoapi/node-sdk'
Require stack:
- /usr/local/lib/node_modules/openclaw/dist/probe-Y2l52Hc0.js
Root cause
Both extensions/discord and extensions/feishu declare these as dependencies in their own package.json files and set bundle.stageRuntimeDependencies: true. However, the build pipeline is not staging these runtime dependencies into dist/ during the npm publish build, so they are missing when installed via npm (as opposed to pnpm from source).
Reproduction
npm install -g openclaw@latest
openclaw --version
# Error: Cannot find module '@buape/carbon'
Workaround
cd /usr/local/lib/node_modules/openclaw
npm install @buape/carbon @larksuiteoapi/node-sdk
Expected fix
The stageRuntimeDependencies pipeline should ensure these packages are either:
- Bundled into the dist output, or
- Added to the published package.json dependencies automatically during the build
Per CLAUDE.md, plugin-only deps should NOT be added to root package.json manually.
Environment
- openclaw 2026.4.5
- Node.js 24.14.1
- Fresh Docker container (node:24-slim)
- Installed via: npm install -g openclaw@latest
Bug
Fresh
npm install -g openclaw@latestcrashes on startup with missing module errors:After manually installing
@buape/carbon, a second missing module appears:Root cause
Both
extensions/discordandextensions/feishudeclare these as dependencies in their ownpackage.jsonfiles and setbundle.stageRuntimeDependencies: true. However, the build pipeline is not staging these runtime dependencies intodist/during the npm publish build, so they are missing when installed via npm (as opposed to pnpm from source).Reproduction
npm install -g openclaw@latest openclaw --version # Error: Cannot find module '@buape/carbon'Workaround
cd /usr/local/lib/node_modules/openclaw npm install @buape/carbon @larksuiteoapi/node-sdkExpected fix
The
stageRuntimeDependenciespipeline should ensure these packages are either:Per CLAUDE.md, plugin-only deps should NOT be added to root package.json manually.
Environment