赞
踩
当我想用pip install 一个库时,遇到以下报错:
WARNING: The repository located at pypi.tuna.tsinghua.edu.cn is not a trusted or secure host and is being ignored. If this repositoryis available via HTTPS we recommend you use HTTPS instead, otherwise you may silence this warning and allow it anyway with '--trusted-host pypi.tuna.tsinghua.edu.cn'.
ERROR: Could not find a version that satisfies the requirement scikit-opt (from versions: none)
ERROR: No matching distribution found for scikit-opt
WARNING: The repository located at pypi.tuna.tsinghua.edu.cn is not a trusted or secure host and is being ignored. If this repository is available via HTTPS we recommend you use HTTPS instead, otherwise you may silence this warning and allow it anyway with '--trusted-host pypi.tuna.tsinghua.edu.cn'.
这个错误提示是由于pip在下载软件包时,发现了一个不受信任的镜像源,因此默认情况下会忽略它。解决方法:找到图中的文件,打开它
编辑:
[global]
timeout = 6000
index-url = http://pypi.tuna.tsinghua.edu.cn/simple/
trusted-host=pypi.tuna.tsinghua.edu.cn
回到cmd,输入:你原本想要下载的内容。
解决方法参考:
python学习日记(1)_warning: the repository located at pypi.tuna.tsing-CSDN博客
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。