我尝试安装python-docx
包,并在下面收到错误消息。
C:\Program Files\Anaconda3\Scripts>pip install python-docx
Collecting python-docx
Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001E9A398CD68>: Failed to establish a new connection: [Errno 11002] getaddrinfo failed',)': /simple/python-docx/
Retrying (Retry(total=3, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001E9A398C240>: Failed to establish a new connection: [Errno 11002] getaddrinfo failed',)': /simple/python-docx/
Retrying (Retry(total=2, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001E9A398C828>: Failed to establish a new connection: [Errno 11002] getaddrinfo failed',)': /simple/python-docx/
Retrying (Retry(total=1, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001E9A398C438>: Failed to establish a new connection: [Errno 11002] getaddrinfo failed',)': /simple/python-docx/
Retrying (Retry(total=0, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001E9A39819B0>: Failed to establish a new connection: [Errno 11002] getaddrinfo failed',)': /simple/python-docx/
Could not find a version that satisfies the requirement python-docx (from versions: )
No matching distribution found for python-docx
答案 0 :(得分:0)
在您的cmd上执行“pip” 你会得到pip的路径(pip-path) 然后做“pip-path install package”或者你可以直接使用“conda install package-name” 因为你有anaconda。
答案 1 :(得分:0)
我唯一的想法是pip有错误的网站,它无法连接到页面,因此无法下载包。所以也许可以直接从网站上下载:https://pypi.python.org/pypi /蟒-DOCX。希望我帮忙。
-Zeus