首先是尝试使用官方源和阿里云 都出现了问题,最后切换豆瓣发现ok了
![[python]阿里云和官方源不好使切换豆瓣源解决问题_开发语言](https://file.cfanz.cn/uploads/png/2023/02/26/2/116ZPVW2CX.png)
image.png
![[python]阿里云和官方源不好使切换豆瓣源解决问题_开发语言_02](https://file.cfanz.cn/uploads/png/2023/02/26/2/dM10YE315X.png)
image.png
![[python]阿里云和官方源不好使切换豆瓣源解决问题_python_03](https://file.cfanz.cn/uploads/png/2023/02/26/2/66E0L3Eee3.png)
image.png
python.exe -m pip install --upgrade pip -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
2设置为信任源
pip config set install.trusted-host pypi.douban.com
D:\dev\ChatGPT\src\revChatGPT>pip config set global.index-url http://pypi.douban.com/simpleWriting to C:\Users\Administrator\AppData\Roaming\pip\pip.ini 如下图所示发现豆瓣没问题,我决定直接设置为永久豆瓣源,并笔记记录下来
![[python]阿里云和官方源不好使切换豆瓣源解决问题_python_04](https://file.cfanz.cn/uploads/png/2023/02/26/2/PP8dddfCe1.png)
image.png
豆瓣:http://pypi.douban.com/simple/
阿里云:http://mirrors.aliyun.com/pypi/simple/
华为云:https://repo.huaweicloud.com/repository/pypi/simple
清华大学:https://pypi.tuna.tsinghua.edu.cn/simple
中科大:https://pypi.mirrors.ustc.edu.cn/simple/
官方:https://pypi.python.org/pyp
echo %HOMEPATH% C:\Users\Administrator\AppData\Roaming\pip\pip.ini
找到配置文件永久信任源
[global]
index-url = http://pypi.douban.com/simple
[install]
trusted-host = pypi.douban.com
