开始的错误是这样的:
NotWritableError: The current user does not have write permissions to a required path.
path: /home/changquan/.conda/envs/.conda_envs_dir_test
uid: 1000
gid: 1000
If you feel that permissions on this path are set incorrectly, you can manually
change them by executing
$ sudo chown 1000:1000 /home/changquan/.conda/envs/.conda_envs_dir_test
In general, it's not advisable to use 'sudo conda'.
应该是乱用sudo 造成的。
用sudo conda env create -f environment.yml创建虚拟环境 错误如下:
Collecting package metadata (repodata.json): failed
CondaHTTPError: HTTP 000 CONNECTION FAILED for url <http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/linux-64/repodata.json>
Elapsed: -
An HTTP error occurred when trying to retrieve this URL.
HTTP errors are often intermittent, and a simple retry will get you on your way.
'http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/linux-64'
后来改变文件夹权限 解决问题:
sudo chown -R changquan /home/changquan/.conda