Hello guys, so i’m following the how-to-npm tutorial and even though it’s not required for me to use npm view in order to proceed, the following is said:
In order to view your package content, I just ran this command:
npm view @steps/mng-pkg-files
Run that command yourself to see what it prints out.
And so i do run it and…
All I get is this:
npm ERR! Linux 4.2.0-c9
npm ERR! argv "/home/ubuntu/.nvm/versions/node/v4.5.0/bin/node" "/home/ubuntu/.nvm/versions/node/v4.5.0/bin/npm" "view"
npm ERR! node v4.5.0
npm ERR! npm v3.10.8
npm ERR! failed to fetch from registry: http://localhost:15443/@steps%2fmng-pkg-files
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR! <https://github.com/npm/npm/issues>
npm ERR! Please include the following file with any support request:
npm ERR! /home/ubuntu/workspace/mng-pkg-files/npm-debug.log
steps:~/workspace/mng-pkg-files (master) $
I could not get how-to-npm to work at all on my computer (I set everything up right, how-to-npm is just buggy), so I just gave up on the tutorials until the new update comes out.
Hopefully someone here knows a better tutorial for it.
It’s sad that I couldn’t get that little feature working, and… lol, I think the remove dist-tag chapter is definitely off, I was unable to point the latest version of my package to a tagged one and had to come up with a sketchy solution.
Let’s see if i recall properly.
So, in this chapter I have to point my package’s default ‘latest’ to a tagged version.
I thought i would either do something with npm dist-tag or maybe npm publish but i got registry or 403 errors accross my attempts. I noticed some of the ‘chapters’ had different kinds of access to the whole package.
So,i started thinking with npm publish --tag=
For me to publish something new i needed a new version. It didn’t matter which version I was in, as long as it was a new one. So, first i went into the version chapter and i bumped a version (npm version patch) then i went into one of the publish chapters and proceeded with the publish -tag=.
Then i went back into the remove dist-tag chapter and verified it. It was successful. I could see with ‘npm dist-tag ls’ that there was only one version, and that version could only be the latest!
I don’t know what I did wrong, what command was I expected to do to point, in the remove dist-tag chapter, to the default ‘latest’ package version?
It’s me or a bug, I guess, either way…it’s done
I ran into this as well. The issue here seems to be due to a bug with the how-to-npm local registry.
I was able to resolve the issue by re-doing the “02 Login” exercise. The steps are:
1.) Go back and run how-to-npm do the 02 Login exercise
2.) Run how-to-npm verify
3.) Run how-to-npm and re-do the 08 Publish exercise (ignore warning about republishing package)
4.) Run how-to-npm verify
5.) You should now be able to run npm view <yourprojectname> without any errors