2

I've gotten this same error on two different npm packages and haven't seemed to be able to figure it out. I've checked this answer and I don't have any other servers running. I've also tried deleting my module_packages folder, cleaning npm cache clean and then reinstalling using npm i as many threads have suggested, but I still get the same error.

  • Windows 10 64bit
  • Node 8.9.4
  • npm 5.6.0

C:\Users\hunter\Documents\vid>npm install npm install github:storj/node-libstorj --save

> storj@5.1.0 preinstall C:\Users\hunter\Documents\vid\node_modules\storj
> node ./download.js

Unable to download libstorj for platform: win32 and arch: x64
npm WARN vid@1.0.0 No repository field.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! storj@5.1.0 preinstall: `node ./download.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the storj@5.1.0 preinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\hunter\AppData\Roaming\npm-cache\_logs\2018-03-25T15_44_06_578Z-debug.log

Any ideas on what might be causing the error would be helpful.

now_world
  • 940
  • 7
  • 21
  • 56

2 Answers2

3

I have good and bad news for you. The good news first: Everythings fine with your computer.

The bad news: The module you would like to install is incompatible with windows operating systems. Have a look at the first line of your error message:

Unable to download libstorj for platform: win32 and arch: x64

There is already an open issue for this problem on GitHub, see: https://github.com/Storj/node-libstorj/issues/43

As mentioned in this issue there are multiple problems:

  • download/unzip not working
  • not compiling because some linux-only functions being used (access function)
  • not linking (it seems nettle and some other link fails)

So you have two options: Wait until this issue gets fixed - or - switch your operating system ;-)

rweisse
  • 820
  • 10
  • 26
  • 1
    Ok, yeah I have contacted them since they said they do support windows (but I'm assuming it's not stable at the moment). Thanks for the explanation. – now_world Mar 25 '18 at 17:40
0

I was getting a "code ELIFECYCLE" error trying to run "usemin" and "imagemin" node-modules via script entries in package.json. These script entries were given in a Coursera "Full Stack Developer" course: "imagemin": "imagemin img/* -o dist/img/ && "usemin": "usemin index.html -d dist -o dist/index.html",

The first line should have read: "imagemin": "imagemin --out-dir=dist/img/ img/**/*.{png,jpg,git}"

And the issue with usemin giving a "code ELIFECYLE" error was finally traced to the fact that I had installed the API version ("npm install usemin") rather than the cli version ("npm install usemin-cli).

Hope the above helps some other nubbie avoid what now look like an obvious pair of mistakes!