npm install error - setting dev env - npm-install

trying set up dev env for kibana
i cloned kibana ; cd kibana
and run npm install
getting the following error :
C:\kibana>npm install
18 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program
Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "elasticsearch"
19 error node v6.10.3
20 error npm v3.10.10
21 error code ELIFECYCLE
22 error kibana#6.0.0-alpha2 elasticsearch: `grunt esvm:dev:keepalive`
22 error Exit status 1
23 error Failed at the kibana#6.0.0-alpha2 elasticsearch script 'grunt esvm:dev:keepalive'.
23 error Make sure you have the latest version of node.js and npm installed.
23 error If you do, this is most likely a problem with the kibana package,
23 error not with npm itself.
23 error Tell the author that this fails on your system:
23 error grunt esvm:dev:keepalive
23 error You can get information on how to open an issue for this project with:
23 error npm bugs kibana
23 error Or if that isn't available, you can get their info via:
23 error npm owner ls kibana
23 error There is likely additional logging output above.
24 verbose exit [ 1, true ]

Related

Can't install material-ui/core for react-native 17.0.1

Would anyone be able to clarify as to why this is not installing as it should?
$ npm install #material-ui/core
Here are the logs:
...
29 http fetch GET 304 https://registry.npmjs.org/react 125ms (from cache)
30 timing idealTree Completed in 2086ms
31 timing command:install Completed in 2090ms
32 verbose stack Error: unable to resolve dependency tree
32 verbose stack at Arborist.[failPeerConflict] (C:\Program Files\nodejs\node_modules\npm\node_modules\#npmcli\arborist\lib\arborist\build-ideal-tree.js:1011:25)
32 verbose stack at Arborist.[loadPeerSet] (C:\Program Files\nodejs\node_modules\npm\node_modules\#npmcli\arborist\lib\arborist\build-ideal-tree.js:991:36)
36 verbose node v15.0.0
37 verbose npm v7.0.2
38 error code ERESOLVE
39 error ERESOLVE unable to resolve dependency tree
40 error
41 error While resolving: [1mamazon-clone[22m#[1m0.1.0[22m
41 error Found: [1mreact[22m#[1m17.0.1[22m[2m[22m
41 error [2mnode_modules/react[22m
41 error [1mreact[22m#"[1m^17.0.1[22m" from the root project
41 error
41 error Could not resolve dependency:
41 error [35mpeer[39m [1mreact[22m#"[1m^16.8.0[22m" from [1m#material-ui/core[22m#[1m4.11.0[22m[2m[22m
41 error [2mnode_modules/#material-ui/core[22m
41 error [1m#material-ui/core[22m#"[1m*[22m" from the root project
41 error
41 error Fix the upstream dependency conflict, or retry
41 error this command with --force, or --legacy-peer-deps
41 error to accept an incorrect (and potentially broken) dependency resolution.
I got chuncks of the logs above that may tell what exactly is going on.
Looks like this post has your solution:
https://github.com/npm/cli/issues/2000. It looks like a recent issue with an eslint dependency

npm not installing packages, shows E404

I am new to node and trying to install express package using npm. It throws error E404. I saw the log file and it is as follow:
Error
2 info using npm#5.6.0
3 info using node#v8.11.1
4 verbose npm-session fe4d5b2eef34bf8f
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 http fetch GET 404 https://registry.npmjs.com/express 639ms
8 silly fetchPackageMetaData error for express#latest 404 Not Found:
express#latest

Unable to install NPM packages due to path length constraint using NPM 5.X

I'm running Windows 10, NPM v5.5.1, and node v8.9.1.
Edit: I have since updated to node v8.9.4 and npm v5.6.0. The problem remains unchanged.
I set up my development environment on this machine about 2 months ago. I'm using Angular CLI to build my client apps.
Everything was going fine. I added a few packages via NPM without a problem, such as Gulp and ngx-bootstrap. Then I started to run into errors on some of my package installs.
The errors are:
npm ERR! code PATH_LENGTH_EXCEEDED
npm ERR! errno PATH_LENGTH_EXCEEDED
npm ERR! request to https://registry/npmjs.org/{{package}} failed, reason: path length constraint exceeded
npm ERR! A complete log of this run can be found in:
npm ERR! {{npm_cache path}}\_logs\2018-02-08T14_43_40_856Z-debug.log
The contents of that log file are:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'install',
1 verbose cli 'ngx-cookie-service',
1 verbose cli '--save' ]
2 info using npm#5.5.1
3 info using node#v8.9.1
4 verbose npm-session d55be12849534a0a
5 silly install loadCurrentTree
6 silly install readLocalPackageData
7 silly fetchPackageMetaData error for ngx-cookie-service#latest request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
8 verbose type system
9 verbose stack FetchError: request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
9 verbose stack at ClientRequest.req.on.err (C:\Program Files\nodejs\node_modules\npm\node_modules\pacote\node_modules\make-fetch-happen\node_modules\node-fetch-npm\src\index.js:68:14)
9 verbose stack at emitOne (events.js:116:13)
9 verbose stack at ClientRequest.emit (events.js:211:7)
9 verbose stack at TLSSocket.socketErrorListener (_http_client.js:387:9)
9 verbose stack at emitOne (events.js:116:13)
9 verbose stack at TLSSocket.emit (events.js:211:7)
9 verbose stack at emitErrorNT (internal/streams/destroy.js:64:8)
9 verbose stack at _combinedTickCallback (internal/process/next_tick.js:138:11)
9 verbose stack at process._tickCallback (internal/process/next_tick.js:180:9)
10 verbose cwd C:\Development\test
11 verbose Windows_NT 10.0.15063
12 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "ngx-cookie-service" "--save"
13 verbose node v8.9.1
14 verbose npm v5.5.1
15 error code PATH_LENGTH_EXCEEDED
16 error errno PATH_LENGTH_EXCEEDED
17 error request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
18 verbose exit [ 1, true ]
I researched this, and found the Windows 10 file path 260 character limitation. I thought that npm version 3.1.0 should have fixed this issue, but I decided to followed the instructions in this answer, because I'm still running into this issue despite using NPM v5.5.1.
I found that my version of Windows was prior to the roll out of the feature that lets you disable this limitation. I updated to Version 1703 (OS Build 15063.483), and to enable Win32 long paths.
Yet I'm still getting the error, and unable to install a variety of npm packages.
In testing to see if it was an issue with packages that have a lot of dependencies, I tried installing or reinstalling a couple of other packages.
Some fail with the errors above. Others succeed with the following warnings:
npm WARN Unexepcted warming for https://registry.npmjs.org/: Miscellaneous Warning PATH_LENGTH_EXCEEDED: request to https://registry.npmjs.org/{{package name}} failed, reason: path length constraint exceeded
npm WARN Using stale package data from https://registry.npmjs.org/ due to a request error during validation
Packages throwing the error include:
jslint
ngx-cookie-service
chart.js
angular-cli
Packages that throw the warnings include:
font-awesome
#angular/cli
moment
ngx-bootstrap
bootstrap
jasmine
I suspect that something has changed, either in a policy on my workstation, or in our network security, that is causing this. All of the packages that succeed seem to be packages that I had previously installed, either as a direct install, or as a dependency of #angular/cli (one of the first packages I installed). I'm assuming that the stale package data warning indicates that whatever problem I have with the path length is preventing updated data being retrieved, and therefore npm is falling back to cached data from previous installations of the selected package and its dependencies.
So now I'm stumped as to how to diagnose exactly where the issue is happening. If its a security policy that changed, then I need to be able to describe exactly what is being blocked so that I can work with our security department to fix this. But the only information I can find about the PATH_LENGTH_EXCEEDED errors lead me to old information about versions of npm prior to 3.1.0.
How can I identify the source of this problem?
After additional searching, I found references to path length exceeded with regards to SSL/TLS certificate authorities. I tested this issue by changing the npm registry to use http instead of https (note: this is a temporary step only; I have turned https back on once I verified the issue):
npm config set registry http://registry.npmjs.org/
This allowed me to install the problematic packages.
It seems the underlying cause is SSL Inspection performed by our network security team. The decryption, inspection, and re-encryption process, and subsequent changes in the Issuing Authority on the certificate, apparently triggers this error.

npm install fails to exec postinstall script bower install

I snooped around the net for more than 48 hours & failed to solve this.
When I run the command 'npm install', it fails to execute the postinstall script 'bower install'. So, I I did an explicit bower install by using:
$npm install -g bower
$bower install
After this, the 'app/bower_components' folder got populated alright. But, again when I try 'npm install', same issue. Unable to proceed further.
I performed the following & did not succeed in installing:
Git is installed & its path added in the PATH environment variable. And then run 'npm install'. Even restarted the command prompt in order for the PATH variable to reflect.
Run 'npm install restify', though I don't know why the installation has to be made a REST service.
I used this, as it was one of the suggestions I came across.
In some post, it was mentioned that it could be due to firewall settings. Disabled the same & tried as well.
Changed all the files under my project 'angular-phonecat' to have read-write permissions. Did this by unchecking 'Read-only' option for the entire folder's contents.
Run Git Bash as admin & tried 'npm install'.
Please help me run this app. :(
Find below my logs:
600 info install angular-phonecat#0.0.0
601 info postinstall angular-phonecat#0.0.0
602 verbose unsafe-perm in lifecycle true
603 info angular-phonecat#0.0.0 Failed to exec postinstall script
604 error angular-phonecat#0.0.0 postinstall: `bower install`
604 error spawn ENOENT
605 error Failed at the angular-phonecat#0.0.0 postinstall script.
605 error This is most likely a problem with the angular-phonecat package,
605 error not with npm itself.
605 error Tell the author that this fails on your system:
605 error bower install
605 error You can get their info via:
605 error npm owner ls angular-phonecat
605 error There is likely additional logging output above.
606 error System Windows_NT 6.2.9200
607 error command "g:\\Workspace\\AngularProjects\\angular-phonecat\\node.exe" "g:\\Workspace\\AngularProjects\\angular-phonecat\\node_modules\\npm\\bin\\npm-cli.js" "install"
608 error cwd g:\Workspace\AngularProjects\angular-phonecat
609 error node -v v0.10.32
610 error npm -v 1.4.28
611 error syscall spawn
612 error code ELIFECYCLE
613 error errno ENOENT
614 verbose exit [ 1, true ]
You will need to provide more information in order to get an answer to this question. It looks like angular-phonecat is your own module that you created -- can you please publish its package.json as a gist https://gist.github.com and attach the link here?
Also, your npm is rather old (and was even at the time you asked this question). I would recommend updating to the latest version of npm, which at this writing is 2.2.0.
To update npm on Windows, follow the instructions here: https://github.com/npm/npm/wiki/Troubleshooting#upgrading-on-windows
Thanks!
try npm-check module to test if any component is outdated

Problems compiling Bootstrap under windows using grunt

I'm trying to compile Bootstrap under windows. I know I'll have to deal with Jakyll later on, but currently im stuck here:
npm install
Which leads to an shasum error when it tries to install sauce-tunnel:
456 error Error: shasum check failed for C:\Users\ME\AppData\Local\Temp\npm-884-8iUK1-Qx\1397291845491-0.2589339539408684\tmp.tgz
456 error Expected: 3afd206b6e853cd508d45f92baf323af9d6a6627
456 error Actual: 13cd33918418cf6f1d305bd7daef22c44cf637bc
456 error From: https://registry.npmjs.org/sauce-tunnel-sc3-1/-/sauce-tunnel-sc3-1-1.0.0.tgz
456 error at C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\sha\index.js:38:8
456 error at ReadStream.<anonymous> (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\sha\index.js:85:7)
456 error at ReadStream.EventEmitter.emit (events.js:117:20)
456 error at _stream_readable.js:920:16
456 error at process._tickCallback (node.js:415:13)
457 error If you need help, you may report this *entire* log,
457 error including the npm and node versions, at:
457 error <http://github.com/npm/npm/issues>
458 error System Windows_NT 6.2.9200
I also tried to install it manually
npm install https://registry.npmjs.org/sauce-tunnel-sc3-1/-/sauce-tunnel-sc3-1-1.0.0.tgz
which only leads to another error:
npm ERR! cb() never called!
npm ERR! not ok code 0
Would be superb, if you could help!
Update: I forgot the Versions:
Node: v0.10.26
NPM: 1.4.3
Bootstrap : Git master (https://github.com/twbs/bootstrap.git)