Anaconda3 导入外部环境报错

更换电脑后,打算把之前anaconda创建的环境,导入到新的机器中,在安装好后,conda env create -f xxx.yaml

报错

Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available)

查询之后发现是SSL出现问题,在下面链接中下载对应的安装包就可以解决

https://slproweb.com/products/Win32OpenSSL.html

Anaconda3 导入外部环境报错_第1张图片

之后进行导入环境操作,又报如下错

Warning: you have pip-installed dependencies in your environment file, but you do not list pip itself as one of your conda dependencies.  Conda may not use the correct pip to install your packages, and they may end up in the wrong place.  Please add an explicit pip dependency.  I'm adding one for you, but still nagging you.
Collecting package metadata: failed

 大致意思是你用pip安装的包,在导入时候可能找不到,所以修改.condarc文件

Anaconda3 导入外部环境报错_第2张图片

 修改内容为

ssl_verify: true
channels:
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
  - https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
show_channel_urls: true

这样再重新导入外部环境时就没有问题了!

你可能感兴趣的:(常用工具)