Installing Vue-CLI, VUE.JS, JavaScript - javascript

I am trying to Install the VUE CLI into my laptop but it gives following errors.
λ npm install -g vue-cli
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! network request to https://registry.nmpjs.org/vue-cli failed, reason: connect ETIMEDOUT 218.93.250.18:443
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\ABDUR REHMAN KHALID\AppData\Roaming\npm-cache\_logs\2018-01-29T07_46_22_789Z-debug.log

This is not a Vue issue. It seems like your registry is set to the wrong url. Set registry to the correct url with:
npm config set registry https://registry.npmjs.org/

if you are trying to install vue-cli then you should try this.
sudo npm install --global vue-cli

Related

why fails create-react-app with "errno ETIMEDOUT npm ERR! network request"

I Have been trying to run React on my local system using the Hyper terminal
I typed the code: npx create-react-app my-apps
it keeps flagging these errors below:
npm ERR! code ETIMEDOUT
npm ERR! syscall connect
npm ERR! errno ETIMEDOUT
npm ERR! network request to http://registry.npmjs.org/#svgr%2fplugin-svgo failed, reason: connect ETIMEDOUT 104.16.26.35:80
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Edmund Obinna\AppData\Local\npm-cache\_logs\2022-02-21T12_17_44_191Z-debug-0.log
Aborting installation.
npm install --no-audit --save --save-exact --loglevel error react react-dom react-scripts cra-template has failed.
Deleting generated file... package.json
Deleting my-apps/ from C:\Users\Edmund Obinna
Done."
try :
npm config rm proxy
then:
npm config rm https-proxy
(https://howtodoinjava.com/angular/npm-install-hung/)
I faced the same issue, I was not behind any proxy, and fixed it by just updating node and npm.
Install n:
npm i -g n
Update node using n:
n lts
Update npm:
npm i -g npm
And then create your react app:
npx create-react-app my-apps
I would also suggest using yarn:
yarn create react-app my-apps

npm install not installing packages

I've tried to get packages to install by running npm install discord.js for example and it doesn't install it. Below is the terminal.
npm ERR! code ECONNRESET
npm ERR! syscall read
npm ERR! errno ECONNRESET
npm ERR! network request to https://registry.npmjs.org/discord.js/-/discord.js-13.1.0.tgz failed, reason: read ECONNRESET
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
This is after a 5-10 minute wait period.
I've done almost everything imaginable. Any help would be appreciated.
Thanks!
XRift_0
Edit
After disabling Kaspersky, it worked. How do I make it work with Kaspersky enabled?
Its trying to use the proxy config set in your PC.
Check the .npmrc file available at C:\Users\yourprofile.npmrc.
Add or remove the proxy config accordingly or delete the .npmrc
proxy=http://proxyserveripordn:proxyport/
https-proxy=http://proxyserveripordns:proxyport
http-proxy=http://proxyusername:proxyuserpassword#proxyserveripordns:proxyport
strict-ssl=false
Try:
npm config set registry http://registry.npmjs.org/
So that npm requests for http url instead of https.
and after this, try the same npm install discord.js command.
This version has been deprecated , now this is no longer in npm

npx create-react-app my-app ERORR: rollbackFailedOptional

The command create-react-app my-app worked fine for the last week that I have been using it and now it is returning the error "rollbackFailedOptional: verb npm-session 895a42364389108b".
I already tried
npm config rm proxy
npm config rm https-proxy
npm config set registry http://registry.npmjs.org/
I am still getting the same error.
Edit:
after letting it fail completely it says the following:
npm ERR! code ENOTFOUND
npm ERR! errno ENOTFOUND
npm ERR! network request to http://registry.npmjs.org/create-react-app failed, reason: getaddrinfo ENOTFOUND domain
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\caleb\AppData\Roaming\npm-cache\_logs\2020-06-05T19_30_34_621Z-debug.log
I figured it out. I did
npm config get proxy
it returned null
So I had to go to "C:\Users\Myname.npmrc", open it in a notepad and then delete whats in there and add
proxy=http://yourorganizationproxy.com:8080
https-proxy=http://yourorganizationproxy.com:8080
As Caleb indicates you should go to "C:\Users\<user>" and check for .npmrc file, then edit with any notepad app. Then you should
Delete everything
Add:
proxy=http://yourorganizationproxy.com:8080
https-proxy=http://yourorganizationproxy.com:8080
strict-ssl=false
Save
Hope it helps

issue installing npm packages

hello guys I'm facing a problem with npm. I can't install any package and whenever I try to install any package it throws this error
npm ERR! code ENOTFOUND
npm ERR! errno ENOTFOUND
npm ERR! network request to https://registry.npmjs.org/semver/-/semver-5.7.1.tgz failed, reason: getaddrinfo ENOTFOUND proxy.company.com
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:

NPM install crashes

My newest npm constantly crashes, when I trying to install some npm package (npm install). I have to repeat this process for example for 5 times before I install all dependencies and even then, It sometimes miss some nested dependencies. So I have to go through the tree and run npm install again.
I tried to use this but with no luck. I'am not behind a proxy. Where should be problem? Installing is taking so long, and my internet connection is not slow.
npm config set registry http://registry.npmjs.org/
c:\work\projects\java\project\frontend-src\node_modules\gulp\node_modules\orchestrator>npm install
npm ERR! fetch failed http://registry.npmjs.org/event-stream/-/event-stream-3.1.7.tgz
npm ERR! fetch failed http://registry.npmjs.org/rcloader/-/rcloader-0.1.2.tgz
npm ERR! fetch failed http://registry.npmjs.org/debug/-/debug-2.1.0.tgz
npm ERR! fetch failed http://registry.npmjs.org/rcloader/-/rcloader-0.1.2.tgz
npm ERR! fetch failed http://registry.npmjs.org/debug/-/debug-2.1.0.tgz
npm ERR! fetch failed http://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz
npm ERR! fetch failed http://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz
npm ERR! fetch failed http://registry.npmjs.org/from/-/from-0.1.3.tgz
npm ERR! fetch failed http://registry.npmjs.org/rcloader/-/rcloader-0.1.2.tgz
npm ERR! network read ECONNRESET
npm ERR! network This is most likely not a problem with npm itself
npm ERR! network and is related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Apps\\nodejs\\\\node.exe" "C:\\Apps\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! cwd c:\work\projects\java\project\frontend-src\node_modules\gulp\node_modules\orchestrator
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! syscall read
npm ERR! code ECONNRESET
npm ERR! errno ECONNRESET
npm ERR! not ok code 0
I don't know how it is possible but these problems disappered after I switched to WIFI on my laptop. I have MSI GT70 which has Killer e2200 Atheros gigabit ethernet. It is likely that cause of this problems is driver/software for manage network traffic (Qualcomm bigfoot) which prefer packets of games. I can't tell for sure because I didn't find any other driver for my configuration.

Categories

Resources