pypa / pipx

Install and Run Python Applications in Isolated Environments
https://pipx.pypa.io
MIT License
10.64k stars 418 forks source link

--verbose does not show pip progress #1576

Open jaymemaurice opened 2 weeks ago

jaymemaurice commented 2 weeks ago

Describe the bug While trying to install a package (say ansible-core on some crusty outdated cygwin), it may take a very long time... the animation does not give much feedback... so enter --verbose.

In my case, --verbose output it quickly sticks on: pipx >(run_subprocess:172): running /home//.local/pipx/venvs/ansible-core/bin/python -m pip install ansible-core

Then after about an hour eventually fails giving further progress of pipx >(subprocess_post_check_handle_pip_error:334): '/home//.local/pipx/venvs/ansible-core/bin/python -m pip install ansible-core' failed pipx >(subprocess_post_check_handle_pip_error:352): Fatal error from pip prevented installation. Full pip output in file: /home//.local/pipx/logs/cmd_2024-11-12_07.27.11_pip_errors.log

The pip_errors log output has the very obvious error that it couldn't install the build dependencies of every single version of cryptography-X.tar.gz.... though it tried diligently to download every version and try anyway... which is why it was taking so long. The root cause of my delay is probably that I don't have the rust compiler needed to build any version of cryptography. Should there have been some sort of console feedback, I could have assumed that if the last few versions of cryptography had not succeeded in their build dependencies, there would be no reason to wait for it to continue to try every version, and I would do the ^C salute.

How to reproduce

run pipx install --verbose ansible-core on cygwin, observe the long wait with no feedback when python -m pip install subprocess is kicked off with no feedback to it's progress

Expected behaviour pipx install --verbose should tee pip install command output to terminal, in real-time, or a more garrulous verbose flag be added.