npm发布错误-“ npm ERR!403 403禁止-禁止的软件包版本”

时间:2020-08-03 12:49:42

标签: node.js npm npm-publish

我试图发布没有npm的软件包的新版本,并出现此错误:

npm ERR! code E403
npm ERR! 403 403 Forbidden - PUT https://registry.npmjs.org/yolo-coords - You cannot publish over the previously published versions: 1.0.4.
npm ERR! 403 In most cases, you or one of your dependencies are requesting
npm ERR! 403 a package version that is forbidden by your security policy.

我的库很短,消息没有意义:

In most cases, you or one of your dependencies are requesting a package version that is forbidden by your security policy

2 个答案:

答案 0 :(得分:1)

问题是我忘记了package.json的{​​{1}}版本:

1.0.4

答案 1 :(得分:0)

尝试使用命令 'npm publish --access=public'