... your network connection. Retrying...
生产服务器出现问题:
/data/cc/jenkins/workspace/workspace/new_ccas/ccas-ui
+ yarn
yarn install v1.22.11
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/4] Resolving packages...
[2/4] Fetching packages...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
error An unexpected error occurred: "https://registry.npmjs.org/@xview-ui/admin-core/-/admin-core-2.0.0.tgz: tunneling socket could not be established, cause=connect ECONNREFUSED 127.0.0.1:1080".
然后通过:
通过 yarn config get registry 确认,没有设置淘宝镜像。
但是为啥通过 yarn 命令安装项目依赖后,生成的 yarn.lock 文件里看到的依然是 https://registry.npm.taobao.o... 呢。如图:
![... your network connection. Retrying...](https://img.it610.com/image/info9/56491c3109d14f23ba57d113782d9075.jpg)
文章图片
【... your network connection. Retrying...】网上很多答案都说是代理问题,不过,设置了代理还是提示这个,后来删除了 yarn.lock 文件后重新 yarn 就好了。估计是 yarn.lock 中包的路径有错,所以一直加载失败。出现此问题可能是 npm 和 yarn 混用导致的。当然,也有可能真的是网络问题。
删了 yarn.lock 文件依然无效可以试下设置代理镜像。
yarn config set registry https://registry.npm.taobao.org
推荐阅读
- ?【段子图】内裤为啥湿呢(想想好邪恶啊...)
- 六月更新的......
- 归乡-序章(世界伊始,人类无所依靠,我的故事就从这里开始...)
- 推荐系统论文进阶|CTR预估 论文精读(十一)--Deep Interest Evolution Network(DIEN)
- 口红选得好,对象不愁找......
- NAT(网络地址转换技术)
- KubeDL HostNetwork(加速分布式训练通信效率)
- 技术|为参加2021年蓝桥杯Java软件开发大学B组细心整理常见基础知识、搜索和常用算法解析例题(持续更新...)
- 安装ambari|安装ambari Hadoop--0(更新中...)
- 清晨朗读327(How|清晨朗读327:How Successful People Network with Each Other)