【问题标题】:problem with node sass npm package node modules节点 sass npm 包节点模块的问题
【发布时间】:2020-10-30 19:28:00
【问题描述】:

命令行中的npm包安装问题,由于节点sass安装尝试未安装而导致几个包的一般问题现在该怎么办它阻止所有包安装发生了什么??

我已经卸载并重新安装了节点它仍然阻止npm,而且给我错误非常慢。发生了什么事,我不知道是什么。

 Windows PowerShell
Copyright (C) Microsoft Corporation. Tous droits réservés.

Testez le nouveau système multiplateforme PowerShell https://aka.ms/pscore6

PS C:\Users\opsty> npm -v
6.14.8
PS C:\Users\opsty> npm install --global --production windows-build-tools
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! network request to https://registry.npmjs.org/windows-build-tools failed, reason: connect ETIMEDOUT 93.184.216.34:8080
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\opsty\AppData\Roaming\npm-cache\_logs\2020-10-30T08_31_04_559Z-debug.log
PS C:\Users\opsty> npm install -g @angular/cli
npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning ETIMEDOUT: request to https://registry.npmjs.org/@angular%2fcli failed, reason: connect ETIMEDOUT 93.184.216.34:8080
npm WARN registry Using stale data from https://registry.npmjs.org/ due to a request error during revalidation.
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! network request to https://registry.npmjs.org/@angular/cli/-/cli-10.2.0.tgz failed, reason: connect ETIMEDOUT 93.184.216.34:8080
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\opsty\AppData\Roaming\npm-cache\_logs\2020-10-30T08_37_03_772Z-debug.log
PS C:\Users\opsty> npm install node-gyp
npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning ETIMEDOUT: request to https://registry.npmjs.org/node-gyp failed, reason: connect ETIMEDOUT 93.184.216.34:8080
npm WARN registry Using stale data from https://registry.npmjs.org/ due to a request error during revalidation.
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! network request to https://registry.npmjs.org/node-gyp/-/node-gyp-7.1.2.tgz failed, reason: connect ETIMEDOUT 93.184.216.34:8080
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\opsty\AppData\Roaming\npm-cache\_logs\2020-10-30T08_43_11_642Z-debug.log
PS C:\Users\opsty>

【问题讨论】:

    标签: node.js npm command-line node-modules npm-install


    【解决方案1】:

    这看起来不像是节点或 npm 问题。会不会是你的 DNS 服务器行为不端?

    换句话说,当您首先看到此类错误时,您需要确保您的计算机可以与https://registry.npmjs.org/ DNS 名称和 93.184.216.34 IP 地址通信。

    【讨论】:

    • 我应该去哪里看这个?以及如何操作?我不知道要遵循的程序
    【解决方案2】:

    问题解决了所以我做了一个 npm config delete proxy npm config delete htpp-proxy 有几种方法

    npm config delete proxy
    npm config delete http-proxy
    npm config delete https-proxy
    
    npm config rm proxy
    npm config rm https-proxy
    
    npm config delete http-proxy
    npm config delete https-proxy
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2023-04-01
      • 2015-03-31
      • 2021-06-29
      • 2017-12-01
      • 2017-03-08
      • 1970-01-01
      • 2022-01-03
      • 1970-01-01
      相关资源
      最近更新 更多