pip安装第三方库时报错Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None))...,详细报错见下图:

报错原因:

国外镜像源连接问题导致

解决:

改为国内镜像源下载

常用国内源:

清华:https://pypi.tuna.tsinghua.edu.cn/simple/

阿里云:http://mirrors.aliyun.com/pypi/simple/

中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/

华中理工大学:http://pypi.hustunique.com/

山东理工大学:http://pypi.sdutlinux.org/

豆瓣:http://pypi.douban.com/simple/

以清华大学镜像源下载为例:

一、直接使用镜像源下载

安装指令:pip install xxx(包名) -i https://pypi.tuna.tsinghua.edu.cn/simple/ --trusted-host pypi.tuna.tsinghua.edu.cn

-i :后为镜像源地址

--trusted-host :后边指的是host,例清华大学镜像源地址为 https://pypi.tuna.tsinghua.edu.cn/simple/,host就是指http://和/之间的部分,即pypi.tuna.tsinghua.edu.cn

备注:其他镜像源下载,-i,--trusted-host后部分更新为使用的镜像源即可,例,改为豆瓣镜像源下载,

   指令为:pip install xxx(包名) -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com

二、配置默认使用某镜像源下载

1,在路径C:\Users\xxx新建pip目录,在该目录下新建pip.ini文件,将下面内容复制到pip.ini文件中,并保存

[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host=pypi.tuna.tsinghua.edu.cn

2,直接pip安装第三方包

指令:pip install xxx(包名)

pip安装第三方库报错Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None))...的更多相关文章

  1. python使用pip安装模块出错 Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None))

    python使用pip安装模块出错 Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) 问题: ...

  2. 使用pip安装第三方库报错记录

    今天在使用pycharm导入第三方库的时候,报了好多超时错误,还有标题中的找不到版本,应该是网络的原因,记录下解决的办法: raise ReadTimeoutError(self._pool, Non ...

  3. pip安装报错: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy

    pip安装报错 解决办法: pip install selenium -i http://pypi.douban.com/simple --trusted-host pypi.douban.com

  4. Python 安装第三方模块时 报Retrying(Retry(total=4, connect=None, read=None, redirect=None, status=None))...[WinError 10061]由于目标计算机积极拒绝,无法连接 错误

    今日在安装ddt模块时(Windows系统),cmd报了一个以前从未见过的错误,如下图所示: 经百度,知是镜像源的问题,将安装命令改成如下命令: pip install ddt -i https:// ...

  5. pycharm 安装第三方库报错:AttributeError: 'module' object has no attribute 'main'

    pip升级到 10.0.1 之后 老版的pycharm 使用pip安装第三方库的时候会报错,报错如上图所示: 其主要原因是 新版的 pip 更改了 部分api 将其中 pip.main() 改为 pi ...

  6. python安装第三方库报错visual c++ 14.0 is required

    使用python安装第三方库时报错如下: error: Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual C++ ...

  7. python-使用pip安装第三方库报UnicodeDecodeError: 'utf8' codec can't decode byte 0xcb in position 7: invalid continuation byte 错误解决方案

    在python 的安装目录下找到Lib\ntpath.py文件,找到def join(path, *paths):方法,添加如下两行语句: reload(sys) sys.setdefaultenco ...

  8. 在安装python 第三方库时遇到【WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, st】问题

    在命令执行窗输入: pip install Pyinstaller -i http://pypi.douban.com/simple --trusted-host pypi.douban.com (其 ...

  9. python安装第三方库报错:Cannot uninstall '***'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

    pip install --ignore-installed ${PACKAGE_NAME}

随机推荐

  1. [Bzoj2243][SDOI2011]染色(线段树&&树剖||LCT)

    题目链接:https://www.lydsy.com/JudgeOnline/problem.php?id=2243 线段树+树链剖分,在线段树需要每次用lt和rt两个数组记录当前区间的左右边界的颜色 ...

  2. ping局域网主机得到外网IP或另一网段IP

    症状::两个笔记本连接到同一个路由器上, 一个ip是 192.168.1.100,主机名是Lenovo-A, 另一个是192.168.1.109,主机名是Lenovo-B 在Lenovo-A 上pin ...

  3. 状压BFS

    ​题意:1个机器人找几个垃圾,求出最短路径. 状压BFS,这道题不能用普通BFS二维vis标记数组去标记走过的路径,因为这题是可以往回走的,而且你也不能只记录垃圾的数量就可以了,因为它有可能重复走同一 ...

  4. 【Spring Boot项目】Win7+JDK8+Tomcat8环境下的War包部署

    一.pom.xml及启动类修改 pom.xml Step1:指定打包类型 <!-- 打包类型 jar 或 war --> <packaging>war</packagin ...

  5. 重置zend studio 默认设置的方法[转]

    这个方法类似于手机的“恢复出厂设置”的功能,就是将所有的使用记录全部清除,用于解决zend studio使用过程中遇到的各种莫名其妙的问题,可以说是zend studio各种问题的终极解决方法~能够解 ...

  6. SIP UserAgent (B2BUA client)——libosip2 libeXosip2

    1. libosip2 libeXosip2 http://www.antisip.com/download/exosip2/ Features:--------eXosip2 has support ...

  7. ipv6地址在URL中的表达方式,如何在URL地址中包含ipv6地址

    摘要 本文档定义了在WWW浏览器的URL中执行的文本IPv6地址的格式.在包括Microsoft的IE,Mozilla和Lynx等几个已经被广泛安装使用的浏览器的IPv6版本中,这种格式已经被使用.并 ...

  8. 第五节:从一条记录说起——InnoDB记录结构

    <MySQL 是怎样运行的:从根儿上理解 MySQL>第五节:从一条记录说起——InnoDB记录结构 准备工作 现在只知道客户端发送请求并等待服务器返回结果.    MySQL什么方式来访 ...

  9. Python3.5-20190529-自动登录百度

  10. linux下清空文件内容

    在命令行下#cat /dev/null >listener.log