npm Community Forum (Archive)

The npm community forum has been discontinued.

To discuss usage of npm, visit the GitHub Support Community.

npm outdated -g nodemon error

What I Wanted to Do

npm outdated -g nodemon

What Happened Instead

npm ERR! Unexpected end of JSON input while parsing near ‘…se":"^4.3.4"},“bin”:{’

Reproduction Steps

npm outdated -g nodemon

Details

Platform Info

$ npm --versions
{ npm: '6.9.1-next.0',
  ares: '1.15.0',
  cldr: '33.1',
  http_parser: '2.8.0',
  icu: '62.1',
  modules: '64',
  napi: '3',
  nghttp2: '1.34.0',
  node: '10.15.3',
  openssl: '1.1.0j',
  tz: '2018e',
  unicode: '11.0',
  uv: '1.23.2',
  v8: '6.8.275.32-node.51',
  zlib: '1.2.11' }
$ node -p process.platform
darwin


Do you see the same error when using npm v6.9.0?

(I am wondering if you have found a bug in 6.9.1-next.0, or might have a corrupt package.)


There was a similar issue with a CDN in the Ireland region a while ago, something to keep in mind if we see more of this in the next few days. Other than that, verifying the cache (or clearing if that doesn’t turn up anything) could be required to fix the problem entirely.

npm help cache

Or the online documentation should have some more information.