18

In my Django application I have a circle.yml file that runs 'pip install -r requirements/base.txt'. When I push up code, and check the CircleCI logs when there is an error, its hard to get to because there are so many dependencies and as of pip6 they started showing progress bars for the installations. Because of that it get busy pretty quick. I read on pip's github page that a few people were requesting a flag to the install command to remove the progress bars, but continue to show everything else like exceptions. something like

pip install --no-progress-bar foo

https://github.com/pypa/pip/pull/4194. It doesn't look like this has been released yet though. Is there any way to currently do this without using --no-cache-dir ?

TJB
  • 3,706
  • 9
  • 51
  • 102

2 Answers2

27

That PR was merged and is available on the latest stable build (pip 10.0.1 at the time of writing). Just do:

pip install foo --progress-bar off

Other args are available. See the pip install docs.

Slava Semushin
  • 14,904
  • 7
  • 53
  • 69
followben
  • 9,067
  • 4
  • 40
  • 42
  • Thanks, this helped me when working with Portainer web terminals -- I would get broken connections during installs, and removing the progress bars solved them. – JeremyDouglass Mar 23 '19 at 21:15
  • Can also set `PIP_PROGRESS_BAR` environment variable, which won't break older pips. – OrangeDog Sep 03 '21 at 14:39
  • It's sad that `pip install -q ...` (quiet flag) doesn't automatically disable this progress bar. – Hugues Jul 04 '22 at 15:27
6

Use pip config to turn these off by default:

pip config --user set global.progress_bar off

(perhaps remove --user for admins, or use replace with --venv for virtualenv)

Jens A. Koch
  • 39,862
  • 13
  • 113
  • 141
Mike T
  • 41,085
  • 18
  • 152
  • 203