I've recently created a new Organization and went for the paid plan to publish unlimited private packages.
However, each time I try to publish my package to my Org, it keeps giving me the following error:
npm ERR! publish Failed PUT 403
npm ERR! code E403
npm ERR! Forbidden : @myScopeName/myPackageName
I've already logged out and then logged in as a scope; like this:
npm login scope=myScopeName
Which then returns the following
logged in as myUserName to scope @myScopeName on http://registry.npmjs.org/
And I've checked my .npmrc
file and I have the following lines:
registry=http://registry.npmjs.org/
scope=myScopeName
@myScopeName:registry=http://registry.npmjs.org
Yet I still can't publish my package. Does anyone know if I've forgotten something else or if I did something wrong according to the above?
Thank you!
This is an error that can have many origins. I will list some of the possibilities below:
Through experimenting, I actually found out that the naming scheme for private npm packages is different than the one officially documented. It appears that privately pushed packages cannot contain underscores, and probably other stuff is also conflicting with the official documents.