Go back and redo the Start A Project step and npm init. Verify.
(This should now insert your username before your package name: @newdygo/fcc - for some reason the first time fails to do that.)
Then go back to the Publish step and redo that. Verify.
Then redo the Version step, incrementing as per the instructions. Verify.
I deleted everything and did the whole project up to that point and it worked. https://github.com/npm/how-to-npm/issues/21 the user “tdbs” suggests that if you do something wrong its hard to get it back to a working state. So I started over and that worked.
deleted the project folder
Went through the whole process again remembering to verify the already verified steps.
I’m confused. I thought I added multiple tags. My latest published version was 2.0.3. I successfully added the tag 2.0.2 (or so I thought). I then ran the verify command and it said I still only had one tag.
Hi thanks for this, I thought it was gonna work but then I run the ‘npm publish’ command and it takes a really long time. Then I get a really weird error message:
npm ERR! code ECONNREFUSED
npm ERR! errno ECONNREFUSED
npm ERR! syscall connect
npm ERR! Error: connect ECONNREFUSED 127.0.0.1:15443
npm ERR! at Object.exports._errnoException (util.js:907:11)
npm ERR! at exports._exceptionWithHostPort (util.js:930:20)
npm ERR! at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1077:14)
npm ERR! { [Error: connect ECONNREFUSED 127.0.0.1:15443]
npm ERR! code: 'ECONNREFUSED',
npm ERR! errno: 'ECONNREFUSED',
npm ERR! syscall: 'connect',
npm ERR! address: '127.0.0.1',
npm ERR! port: 15443 }
npm ERR!
npm ERR! If you are behind a proxy, please make sure that the
npm ERR! 'proxy' config is set properly. See: 'npm help config'
Okay guys, here is how I fixed the problem. Everyone has you thinking you’re typing your code wrong, and maybe so, but there is one other thing you need to know: updating your version properly.
Type npm version and look at the first line to find out the name and pkg version # that you’re dealing with.
1a. Here was mine: @thelynguist/chat-example@1.2.3 (it actually looked more like:
'@thelynguist/chat-example:' '1.2.3'
…but that’s not how you’ll be typing it, so don’t worry about that)
You MUST change this version number, and not how you may think.
2a. In the “version” step (step 9), they say typing npm version will automatically update your version #, but it DOESN’T.
2b. So, go up to your json file and manually update it to name: @thelynguist/chat-example version: 1.2.4.
2c. DO NOT just save it. I tried and it didn’t work. You must also refresh your page after you save it.
2d. This will update your version number (the thing it’s fussing about that nobody understands).
NOW you can publish again: npm publish. Verify and continue.
From here they also want you to add a “tag” (dist-tag) to this new published version.
4a. thelynguist/chat-example@1.2.4 beta
It should work from there.
Somehow, we’re able to pass the “publish again” stage without really passing. That is, your version number has not been updated (at least, I passed, despite my number not being updated). So when you go to add the new tag, it doesn’t want to go through. That’s why dhcodes’ solution didn’t quite work for me, and possibly not for you either.