Hello team, I am facing a strange issue regarding ...
# general
m
Hello team, I am facing a strange issue regarding Pants downloading
whl
files. Pants fail to download
whl
files but when I manually
curl
the URL it works. Could anyone give me some pointers on how to debug this please?
Copy code
ProcessExecutionFailure: Process 'Building black.pex from <resource://pants.backend.python.lint.black/black.lock>' failed with exit code 1.
stdout:

stderr:
There were 8 errors downloading required artifacts:
1. black 24.8 from <https://files.pythonhosted.org/packages/7a/b4/d34099e95c437b53d01c4aa37cf93944b233066eb034ccf7897fa4e5f286/black-24.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl>
    pip: pip._vendor.requests.exceptions.ConnectionError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Max retries exceeded with url: /packages/7a/b4/d34099e95c437b53d01c4aa37cf93944b233066eb034ccf7897fa4e5f286/black-24.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (Caused by NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fe77955b1f0>: Failed to establish a new connection: [Errno 101] Network is unreachable'))
f
Just the usual networking advice. Is your
curl
configured to proxy through a proxy server?
Maybe use
tcpdump
or WireShark to monitor the network activity when
pip
tries to download?
But first, you can use
--keep-sandboxes=on_failure
to preserve the pex/pip execution which failed in your case.
Then use the
__run.sh
script in the preserved sandbox to manually run the pex/pip command again and see if you still see the error.
m
Thank you for the pointers... really appreciate it!