npm Community Forum (Archive)

The npm community forum has been discontinued.

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

Could not install from (MODULE) as it does not contain a package.json file, but it does

What I Wanted to Do

I wanted to npm install all my dependencies like I usually do for MetaMask.

What Happened Instead

I got an error:

npm ERR! Could not install from "node_modules/eth-tx-summary/node_modules/eth-block-tracker/async-eventemitter@github:ahultgren/async-eventemitter#fa06e39e56786ba541c180061dbf2c0a5bbf951c" as it does not contain a package.json file.

Reproduction Steps

Pull that repo, and try to npm install with node v8.15.

Or try to npm install ahultgren/async-eventemitter#fa06e39e56786ba541c180061dbf2c0a5bbf951c

Details

That repository at that commit does in fact have a package.json file.

This issue was reported on the old github repository but went unfixed.

This issue was raised on this forum but was told it was mis-formatted.

Platform Info

I’ve tried a couple versions.

$ npm --versions
{ 'metamask-crx': '0.0.0',
  npm: '6.9.0',
  ares: '1.15.0',
  brotli: '1.0.7',
  cldr: '35.1',
  http_parser: '2.8.0',
  icu: '64.2',
  modules: '64',
  napi: '4',
  nghttp2: '1.34.0',
  node: '10.16.0',
  openssl: '1.1.1b',
  tz: '2019a',
  unicode: '12.1',
  uv: '1.28.0',
  v8: '6.8.275.32-node.52',
  zlib: '1.2.11' }

Older:

$ npm --versions
{ 'metamask-crx': '0.0.0',
  npm: '6.9.0',
  ares: '1.10.1-DEV',
  cldr: '32.0',
  http_parser: '2.8.0',
  icu: '60.1',
  modules: '57',
  napi: '3',
  nghttp2: '1.32.0',
  node: '8.11.3',
  openssl: '1.0.2o',
  tz: '2017c',
  unicode: '10.0',
  uv: '1.19.1',
  v8: '6.2.414.54',
  zlib: '1.2.11' }