MiniMax-AI / MiniMax-AI/minimax-code
[Bug]: npm install -g @minimax-ai/code prints deprecation warning for prebuild-install@7.1.3 (transitive via better-sqlite3@12.11.1)
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.3k
- Forks
- 141
- Avg merge
- 2h 45m
- Merged PRs (30d)
- 46
Description
What happened
Running npm install -g @minimax-ai/code (or npm update -g) prints a deprecation warning for a transitive dependency. The warning is noise today, but prebuild-install is officially unmaintained, so future Node or prebuild-mirror changes could turn this into a real install failure.
npm warn deprecated prebuild-install@7.1.3: No longer maintained. Please contact the author of the relevant native addon; alternatives are available.
Where it comes from
The deprecated package is pulled in transitively via better-sqlite3, which @minimax-ai/code lists as an optionalDependency:
@minimax-ai/code@0.1.6
└─ optionalDependencies
└─ better-sqlite3@12.11.1
└─ prebuild-install@7.1.3 ← deprecated, unmaintained
better-sqlite3 is only used by verify-native-install.mjs (the postinstall smoke test that runs SELECT 1 AS value). The main cli.js and matrix-mcp-stdio.js do not require("better-sqlite3").
Environment
- MCode CLI: 0.1.6 (npm
@minimax-ai/code) - npm: 11.10.0
- Node.js: 22.22.0 (within the supported range
>=22.19 <23 || >=24 <27) - OS: Windows 11 家庭中文版 (build 26200)
- Install command:
npm install -g @minimax-ai/code
Steps to reproduce
- Uninstall any prior copy:
npm uninstall -g @minimax-ai/code npm install -g @minimax-ai/code- Read the npm output
Expected behavior
No deprecation warnings. better-sqlite3 is only used for a one-line postinstall smoke test, so carrying an unmaintained transitive dep is not worth the cost.
Suggested fix
Either of these would clear the warning with no behavior change:
-
Bump
optionalDependencies.better-sqlite3to^13.0.0.better-sqlite3@13.xdropsprebuild-installentirely (onlynode-addon-apiremains), ships prebuilds via the packageexportsfield, and requires Node ≥ 22, which already matches MCode's supported Node range. -
Drop
better-sqlite3fromoptionalDependencies(andverify-native-install.mjs) if the runtime doesn't actually need it. I checked the installed bundle — the only consumer ofbetter-sqlite3is the postinstall smoke test.
I tested option 1 locally on Windows 11: the smoke test still passes with better-sqlite3@13.0.3 (SELECT 1 AS value returns { value: 1 }), and npm install no longer prints any deprecation warning.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Inspect the package manifest's optionalDependencies and verify-native-install.mjs, the postinstall smoke test that runs SELECT 1 AS value. Reproduce the global install warning, then verify that the chosen dependency change or removal eliminates the deprecation warning while the smoke test still passes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100