Closed
Description
Is there an existing issue for this?
- I have searched the existing issues
This issue exists in the latest npm version
- I am using the latest npm
Current Behavior
If you have lockfile-version=5
by mistake (or anything other than missing, 1, 2 or 3) in the .npmrc, npm warnings/errors show a non-uniq list of error cases - null, 1, 2, 3, 1, 2, 3
npm WARN invalid config lockfile-version="5" set in /Users/REDACTED/REDACTED/REDACTED-website/.npmrc
npm WARN invalid config Must be one of: null, 1, 2, 3, 1, 2, 3
npm ERR! Invalid lockfileVersion config: 5
Expected Behavior
Should uniq, and return just null, 1, 2, 3
npm WARN invalid config lockfile-version="5" set in /Users/REDACTED/REDACTED/REDACTED-website/.npmrc
npm WARN invalid config Must be one of: null, 1, 2, 3
npm ERR! Invalid lockfileVersion config: 5
Steps To Reproduce
With npm 9.6.5
have a package.json and an .npmrc
in the .npmrc, have this
lockfile-version=5
run npm install
Get the warning
Environment
- npm: 9.6.5
- Node.js: v18.16.0
- OS Name: Mac