Anaconda创建虚拟环境报错—UnavailableInvalidChannel: The channel is not accessible or is invalid

目录

报错

Collecting package metadata (current_repodata.json): failed

UnavailableInvalidChannel: The channel is not accessible or is invalid.
  channel name: simple
  channel url: https://pypi.tuna.tsinghua.edu.cn/simple
  error code: 404

You will need to adjust your conda configuration to proceed.
Use `conda config --show channels` to view your configuration's current state,
and use `conda config --show-sources` to view config file locations.

解决

看错误的大致意思,应该是镜像源的问题。查了一下,果然是真的。
在这里插入图片描述
在cmd下输入

conda config --remove-key channels

只需恢复默认源即可,至此问题解决

PS:不过不要担心
在这里插入图片描述
哈哈哈,又回来了

修改镜像源

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
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/cloud/msys2/

# 设置搜索时显示通道地址
conda config --set show_channel_urls yes

可以显示添加的来源

conda config --show channels

在这里插入图片描述

文章出处登录后可见!

已经登录?立即刷新

共计人评分,平均

到目前为止还没有投票!成为第一位评论此文章。

(0)
心中带点小风骚的头像心中带点小风骚普通用户
上一篇 2022年3月21日 下午12:41
下一篇 2022年3月21日 下午12:57

相关推荐