Could not install from "git+https@github.com/..." as it does not contain a package.json file.

What I Wanted to Do

npm install

What Happened Instead

mha@mint-virtual-machine ~/neo $ npm install
npm ERR! code ENOLOCAL
npm ERR! Could not install from "git+https@github.com/refinio/one.git" as it does not contain a package.json file.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/mha/.npm/_logs/2018-12-23T12_20_36_099Z-debug.log

and in the log file, the last lines are

21 verbose stack Error: ENOENT: no such file or directory, open '/home/mha/neo/git+https@github.com/refinio/one.git/package.json'
22 verbose cwd /home/mha/neo
23 verbose Linux 4.15.0-43-generic
24 verbose argv "/usr/bin/node" "/usr/bin/npm" "install"
25 verbose node v11.5.0
26 verbose npm  v6.5.0
27 error code ENOLOCAL
28 error Could not install from "git+https@github.com/refinio/one.git" as it does not contain a package.json file.
29 verbose exit [ 1, true ]

Reproduction Steps

Private repo, and no idea how I got into that state

Details

I had indeed erroneously removed the package.json file in a commit, I noticed it when “npm install” from another repo for that now broken private Github-URL repo failed.

I FIXED IT THOUGHT, and now there again is a package.json file in master, from which I install via Github URL (see subject line).

npm STILL claims there is no package.json! I did an “npm cache verify” and even an “npm cache clean --force”.

Platform Info

$ npm --versions
{ 'one.neo': '0.2.0',
  npm: '6.5.0',
  ares: '1.15.0',
  cldr: '34.0',
  http_parser: '2.8.0',
  icu: '63.1',
  llhttp: '1.0.1',
  modules: '67',
  napi: '3',
  nghttp2: '1.34.0',
  node: '11.5.0',
  openssl: '1.1.0j',
  tz: '2018e',
  unicode: '11.0',
  uv: '1.24.0',
  v8: '7.0.276.38-node.13',
  zlib: '1.2.11' }

$ node -p process.platform
linuix

Okay, so apparently that URL syntax was the problem. HOWEVER, I had used that exact same syntax for some time and only now was there this problem.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.