HTTPSConnectionPool(host=’files.pythonhosted.org’, port=443): Read timed out.

Problem

When trying to install big-size libraries like requests that depend on url3 or Scipy on low-speed internet it always fails because there is a 30sec default timeout.

Fail example:

line 443, in _error_catcher
raise ReadTimeoutError(self._pool, None, "Read timed out.")
pipenv.patched.pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.

Solution

Set default timeout for pipenv pip by:

mkdir $HOME/.config/pip/
touch $HOME/.config/pip/pip.conf
echo -e "[global]\ntimeout = 3600"> $HOME/.config/pip/pip.conf

Leave a Reply

Your email address will not be published. Required fields are marked *

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Select your currency
EGP Egyptian pound