The repository located at mirrors.aliyun.com is not a trusted or secur
http://%77%77%77%2E%66网站制作%6F学习网%72%61%73%70%2E%63%6E
在用python pip 安装软件试试,经常连不上源网,需要用国内的网
首先,比如pip 安装 pandas ,如果用 原始源 ,不用任何配置
命令:
pip install pandas
如果用国内的源,下面先说 一下源
阿里云 http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/
豆瓣(douban) http://pypi.douban.com/simple/
清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/
中国科学技术大学 http://pypi.mirrors.ustc.edu.cn/simple/
如果我们用国内源 安装,命令如下
pip install pandas -i http://mirrors.aliyun.com/pypi/simple/
但是会出现这样的提示:
WARNING: The repository located at mirrors.aliyun.com 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 mirrors.aliyun.com'.
如果用 清华的源,则会对应出现清华源不安全提示。
WARNING: The repository located at mirrors.aliyun.com 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'.
上面意思是,不能用http 需要用https 。这里切记,不要换https ,这回导致一系列麻烦。
解决方法如下:
pip install pandas -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com
forasp.cn