解决使用Dockerfile来build镜像时pip install遇到的BUG

简介: 解决使用Dockerfile来build镜像时pip install遇到的BUG

错误如下,遇到第二次了,而且看到网上很多回答并不管用,当然也可能是对应的问题不太相同。


Collecting requests (from -r requirements.txt (line 1))


Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f443a504350>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',)': /simple/requests/
  Retrying (Retry(total=3, connect=None, read=None, redirect=None)) after connection broken by


'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f443a504990>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',)': /simple/requests/
  Retrying (Retry(total=2, connect=None, read=None, redirect=None)) after connection broken by


'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f443a504390>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',)': /simple/requests/
  Retrying (Retry(total=1, connect=None, read=None, redirect=None)) after connection broken by


'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f443a504090>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',)': /simple/requests/
  Retrying (Retry(total=0, connect=None, read=None, redirect=None)) after


connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f443a504a50>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',)': /simple/requests/


解决方法:service docker restart


20190503091605497.png

目录
相关文章
|
5月前
pip install --upgrade transformers
pip install --upgrade transformers
84 1
|
11月前
pip配置阿里镜像
pip配置阿里镜像
|
4月前
pip install -U weditor 安装报错 error: subprocess-exited-with-error
pip install -U weditor 安装报错 error: subprocess-exited-with-error
80 0
|
8月前
|
Linux Shell Python
python第三方库 pip install速度慢的解决办法
python第三方库 pip install速度慢的解决办法
210 0
|
8天前
|
存储 Scala 索引
【零碎知识】pip install 与 conda install 的区别
【零碎知识】pip install 与 conda install 的区别
19 0
|
2月前
|
Python Windows
解决Python下pip install MySQL-python失败的问题
解决Python下pip install MySQL-python失败的问题
23 0
|
3月前
|
Unix Linux Python
sudo python -m pip install --upgrade pip
sudo python -m pip install --upgrade pip是一个用于升级Python包管理器pip的命令。这个命令由pip模块提供,它是一个Python包管理器,用于安装、升级和删除Python软件包。--upgrade选项表示要执行升级操作。
50 1
|
5月前
|
网络安全 C语言 Python
Python【问题 01】pip install MySQL-python==1.2.4b4 依赖安装问题记录及解决
Python【问题 01】pip install MySQL-python==1.2.4b4 依赖安装问题记录及解决
35 0
|
6月前
|
Python
python2 pip2 pip install web.py No module named wsgiserver
python2 pip2 pip install web.py No module named wsgiserver
26 0
|
6月前
|
Python
Python pip install修改默认下载路径
Python pip install修改默认下载路径
140 0