OS系统 解决Anaconda出现 CondaHTTPError : HTTP 000 CONNECTION FAILED for url 问题

利用清华镜像 https://mirrors.tuna.tsinghua.edu.cn/help/anaconda/
我下载了anaconda,然后想新创建一个环境,
当我新建一个环境的时候在这里插入图片描述
按图形界面指示,点击create,准备创建,然后就会返回报错:
CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://repo.anaconda.com/pkgs/r/osx-64/current_repodata.json><br>Elapsed: -<br><br>An HTTP error occurred when trying to retrieve this URL.<br>HTTP errors are often intermittent, and a simple retry will get you on your way.<br><br>If your current network has https://www.anaconda.com blocked, please file<br>a support request with your network engineering team.<br><br>'https://repo.anaconda.com/pkgs/r/osx-64'<br>

处理方法如下:

1. 首先在terminal命令行执行如下几条命令,用来更换清华镜像源

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/

conda config --set show_channel_urls yes

按回车执行操作,如下图示:
在这里插入图片描述

2.更改镜像源配置文件
直接在apple下搜索文件condarc,找到它,在我的电脑里他的具体位置如下(如果你也是一直默认安装那应该和我一样)
在这里插入图片描述
然后,打开这个condarc文件,尽行如下修改:
在这里插入图片描述

然后就结束了,重新再次create一下环境就可以成功了!

参考并感谢大佬博客!
参考链接:https://blog.csdn.net/Copper01/article/details/97134974?utm_medium=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-2.control&depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-2.control

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值