pytorch / pytorch

Tensors and Dynamic neural networks in Python with strong GPU acceleration
https://pytorch.org
Other
82.88k stars 22.34k forks source link

Flaky download from files.pythonhosted.org when installing botocore #14478

Open ezyang opened 5 years ago

ezyang commented 5 years ago

Log: https://circleci.com/gh/pytorch/pytorch/316264?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link

Exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 278, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1198, in prepare_files
    do_download,
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1376, in unpack_url
    self.session,
  File "/usr/lib/python2.7/dist-packages/pip/download.py", line 546, in unpack_http_url
    resp = session.get(target_url, stream=True)
  File "/usr/share/python-wheels/requests-2.2.1-py2.py3-none-any.whl/requests/sessions.py", line 467, in get
    return self.request('GET', url, **kwargs)
  File "/usr/lib/python2.7/dist-packages/pip/download.py", line 237, in request
    return super(PipSession, self).request(method, url, *args, **kwargs)
  File "/usr/share/python-wheels/requests-2.2.1-py2.py3-none-any.whl/requests/sessions.py", line 455, in request
    resp = self.send(prep, **send_kwargs)
  File "/usr/share/python-wheels/requests-2.2.1-py2.py3-none-any.whl/requests/sessions.py", line 558, in send
    r = adapter.send(request, **kwargs)
  File "/usr/share/python-wheels/requests-2.2.1-py2.py3-none-any.whl/requests/adapters.py", line 378, in send
    raise ConnectionError(e)
ConnectionError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Max retries exceeded with url: /packages/53/80/8328098290ca3bfeca05b96c4041c5a7f861219c22624ff482aa859107e9/botocore-1.12.25-py2.py3-none-any.whl (Caused by <class 'socket.error'>: [Errno 104] Connection reset by peer)

Storing debug log for failure in /home/circleci/.pip/pip.log

I'm not sure what we should do here: we can't preload botocore onto our Docker image, because this happens before we have gotten our Docker image.

ezyang commented 5 years ago

CC @yf225

yf225 commented 5 years ago

If this happens quite often, we can probably host the botocore wheel file in our S3 and download from there.

ezyang commented 5 years ago

Another occurrence: https://circleci.com/gh/pytorch/pytorch/327744?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link

ezyang commented 5 years ago

Another occurrence: https://circleci.com/gh/pytorch/pytorch/346498?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link/console