chore: add npm >=11.10 engine constraint to enforce min-release-age - #918
chore: add npm >=11.10 engine constraint to enforce min-release-age#918Xsidz wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
This PR aims to ensure the repo’s min-release-age=7 supply-chain cooldown is not silently bypassed by older npm versions by declaring an npm version floor via engines in the root package.json.
Changes:
- Added
"npm": ">=11.10"to the rootpackage.jsonenginesfield. - Documented the change in
packages/coding-agent/CHANGELOG.mdunder[Unreleased].
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| package.json | Adds an npm engine constraint intended to surface a mismatch when using npm versions that don’t enforce min-release-age. |
| packages/coding-agent/CHANGELOG.md | Adds an Unreleased entry describing the new npm engine constraint and its motivation. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Xsidz
left a comment
There was a problem hiding this comment.
Good catch. Added engine-strict=true to .npmrc in the follow-up commit (0c2d1cc3) — this makes installs with npm < 11.10 fail outright rather than just warn, so the constraint is now a hard gate. Also updated the changelog wording to say "fail fast instead of silently ignoring" rather than "actually enforced".
ffb32de to
154a044
Compare
Older npm versions silently ignore the min-release-age=7 setting in .npmrc. Adding the engine floor makes the supply-chain cooldown actually enforced instead of advisory. fixes PrimeIntellect-ai#874
engine-strict makes the engines.npm>=11.10 constraint a hard failure instead of a warning, so installs with older npm actually fail rather than silently proceeding without min-release-age enforcement. Also tightens the CHANGELOG wording to accurately describe the behavior (fail-fast vs. advisory).
154a044 to
c7bd09d
Compare
Summary
"npm": ">=11.10"to the rootenginesfield inpackage.json.Without this constraint,
min-release-age=7in.npmrcis silently ignored by npm < 11.10, allowing dependency installs and version scripts to bypass the 7-day supply-chain cooldown. The engine floor makes the requirement explicit and enforced.Test plan
npm run checkpasses (biome, tsgo, installer render, browser smoke)Fixes #874
Note
Add npm >=11.10 engine constraint with strict enforcement
npm: '>=11.10'to theenginesfield in package.json to enforce the minimum npm version required formin-release-agesupport.engine-strict=truein .npmrc so thatnpm installerrors out when the engine constraints are not met.Macroscope summarized c7bd09d.