I'm unable to install any python package using pip. Everything used to work perfectly until a few days back. But now I get the following errors while installing. I think the issue is because of the URLs that pip uses to fetch the wheel packages. Now I install all these packages by manually downloading the package wheels, but it's very cumbersome task.
Python version: 3.5.2, OS: Ubuntu 16.04
Command: pip -v install pandas
Log:
Created temporary directory: /tmp/pip-ephem-wheel-cache-qfdazbyv
Created temporary directory: /tmp/pip-install-sew6kypd
Collecting pandas
1 location(s) to search for versions of pandas:
* https://pypi.python.org/simple/pandas/
Getting page https://pypi.python.org/simple/pandas/
Looking up "https://pypi.python.org/simple/pandas/" in the cache
Returning cached "301 Moved Permanently" response (ignoring date and etag information)
Looking up "https://pypi.org/simple/pandas/" in the cache
No cache entry available
Starting new HTTPS connection (1): pypi.org
Incremented Retry for (url='/simple/pandas/'): Retry(total=4, connect=None, read=None, redirect=None, status=None)
Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))': /simple/pandas/
Starting new HTTPS connection (2): pypi.org
Incremented Retry for (url='/simple/pandas/'): Retry(total=3, connect=None, read=None, redirect=None, status=None)
Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))': /simple/pandas/
Starting new HTTPS connection (3): pypi.org
Incremented Retry for (url='/simple/pandas/'): Retry(total=2, connect=None, read=None, redirect=None, status=None)
Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))': /simple/pandas/
Starting new HTTPS connection (4): pypi.org
Incremented Retry for (url='/simple/pandas/'): Retry(total=1, connect=None, read=None, redirect=None, status=None)
Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))': /simple/pandas/
Starting new HTTPS connection (5): pypi.org
Incremented Retry for (url='/simple/pandas/'): Retry(total=0, connect=None, read=None, redirect=None, status=None)
Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))': /simple/pandas/
Starting new HTTPS connection (6): pypi.org
Could not fetch URL https://pypi.python.org/simple/pandas/: connection error: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pandas/ (Caused by ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))) - skipping
Could not find a version that satisfies the requirement pandas (from versions: )
Cleaning up...
No matching distribution found for pandas
Exception information:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/basecommand.py", line 228, in main
status = self.run(options, args)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/commands/install.py", line 291, in run
resolver.resolve(requirement_set)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/resolve.py", line 103, in resolve
self._resolve_one(requirement_set, req)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/resolve.py", line 257, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/resolve.py", line 210, in _get_abstract_dist_for
self.require_hashes
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/operations/prepare.py", line 243, in prepare_linked_requirement
req.populate_link(finder, upgrade_allowed, require_hashes)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/req/req_install.py", line 307, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "/usr/local/lib/python3.5/dist-packages/pip/_internal/index.py", line 533, in find_requirement
'No matching distribution found for %s' % req
pip._internal.exceptions.DistributionNotFound: No matching distribution found for pandas
1 location(s) to search for versions of pip:
* https://pypi.python.org/simple/pip/
Getting page https://pypi.python.org/simple/pip/
Looking up "https://pypi.python.org/simple/pip/" in the cache
Returning cached "301 Moved Permanently" response (ignoring date and etag information)
Looking up "https://pypi.org/simple/pip/" in the cache
No cache entry available
Starting new HTTPS connection (1): pypi.org
Could not fetch URL https://pypi.python.org/simple/pip/: connection error: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by ProtocolError('Connection aborted.', ConnectionResetError(104, 'Connection reset by peer'))) - skipping