← Back to PRs

#20278: Fix/matrix missing bot sdk dependency

by saurav470 open 2026-02-18 18:39 View on GitHub →
size: XS
Fixes an issue where the Matrix plugin failed to load after installation or updates because @vector-im/matrix-bot-sdk was not included as a dependency in the OpenClaw npm package. #19840 <!-- greptile_comment --> <h3>Greptile Summary</h3> Adds `@vector-im/matrix-bot-sdk`, `@matrix-org/matrix-sdk-crypto-nodejs`, and `music-metadata` to the root `package.json` so that the bundled Matrix extension can resolve its runtime dependencies after `npm install -g openclaw`. - The Matrix extension ships inside the `extensions/` directory included in the npm package. Bundled extensions are loaded at runtime via `jiti` without a separate `npm install` step, so Node module resolution walks up to the root `node_modules` — these deps must be present there. - All three version specifiers match `extensions/matrix/package.json` exactly. The remaining Matrix deps (`zod`, `markdown-it`) were already in the root `package.json`. - The `pnpm-lock.yaml` changes include expected additions plus benign deduplication of `axios` and `follow-redirects` entries. - Note: `AGENTS.md` states "Keep plugin-only deps in the extension `package.json`; do not add them to the root `package.json` unless core uses them." This PR is a justified exception — bundled extensions need their deps resolvable from root `node_modules` since no per-extension `npm install` runs for bundled plugins. The guideline may warrant updating to reflect this pattern. <h3>Confidence Score: 5/5</h3> - This PR is safe to merge — it adds only dependency declarations with no logic changes. - The PR makes a minimal, well-scoped change: adding three dependency entries to root package.json so the bundled Matrix extension can resolve its imports at runtime. Version specifiers match the extension's own package.json exactly. The lockfile changes are clean with only expected additions and benign deduplication. No code logic is modified. - No files require special attention. <sub>Last reviewed commit: d668455</sub> <!-- greptile_other_comments_section --> **Context used:** - Context from `dashboard` - CLAUDE.md ([source](https://app.greptile.com/review/custom-context?memory=fd949e91-5c3a-4ab5-90a1-cbe184fd6ce8)) - Context from `dashboard` - AGENTS.md ([source](https://app.greptile.com/review/custom-context?memory=0d0c8278-ef8e-4d6c-ab21-f5527e322f13)) <!-- /greptile_comment -->

Most Similar PRs