Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
When I run npm publish, after I successfully provide the OTP in the browser, the NPM CLI errors with:
400 Bad Request - PUT https://registry.npmjs.org/@incanta%2fconfig - child "otp" fails because ["otp" with value "[object Object]" fails to match the required pattern: /^\d+$/, "otp" length must be 64 characters long]
Downgrading to npm@10.7.0 publishes the update without any issue.
Expected Behavior
The package should publish without error.
Steps To Reproduce
- Use the latest NPM
npm i -g npm@10.8.0
- Clone
https://github.com/incanta/node-config
- Install yarn v1
npm i -g yarn
- Install deps:
yarn
- Build TypeScript:
yarn build
- Change the
package.json package name so you can publish it
- Publish:
npm publish
- Provide OTP in browser
- Return to CLI to see the version
- See the error in the CLI
Repeat these steps after downgrading NPM npm i -g npm@10.7.0 to see that you can publish.
Environment
- npm: 10.8.0
- Node.js: 20.13.1
- OS Name: Windows 11 Pro
- System Model Name: Custom built desktop PC
- npm config:
; "user" config from C:\Users\seese\.npmrc
@fortawesome:registry = "https://npm.fontawesome.com/"
//npm.fontawesome.com/:_authToken = (protected)
//registry.npmjs.org/:_authToken = (protected)
msbuild_path = "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\Msbuild\\Current\\Bin\\MSBuild.exe"
msvs_version = "2022"
; node bin location = C:\Program Files\nodejs\node.exe
; node version = v20.13.1
; npm local prefix = D:\work\node-config
; npm version = 10.7.0
; cwd = D:\work\node-config
; HOME = C:\Users\seese
; Run `npm config ls -l` to show all defaults.
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
When I run
npm publish, after I successfully provide the OTP in the browser, the NPM CLI errors with:Downgrading to
npm@10.7.0publishes the update without any issue.Expected Behavior
The package should publish without error.
Steps To Reproduce
npm i -g npm@10.8.0https://github.com/incanta/node-confignpm i -g yarnyarnyarn buildpackage.jsonpackage name so you can publish itnpm publishRepeat these steps after downgrading NPM
npm i -g npm@10.7.0to see that you can publish.Environment