question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

pipenv couldn't display progress bar when it downloads package

See original GitHub issue

I sometimes download big package such as pytorch. When my network speed is slow, the progress of downloading will take long time to execute. The output in the consolse just spin and don’t give me more feedback like download speed or complete rate. I have try add --verbose but don’t work as my exception. I could use pip to isntall and use pipenv to lock, but this solution not sound good. I am wondering if pipenv have feature like $ pip install torch --progress-bar=on and something like this:

  Downloading https://files.pythonhosted.org/packages/69/43/380514bd9663f1bf708abeb359b8b48d3fabb1c8e95bb3427a980a064c57/torch-0.4.0-cp36-cp36m-manylinux1_x86_64.whl (484.0MB)
    0% |                                | 563kB 248kB/s eta 0:32:28

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:12
  • Comments:15 (2 by maintainers)

github_iconTop GitHub Comments

6reactions
Alexander3commented, Jan 21, 2019

It would be nice to have some kind of indication what pipenv is doing. Now I get output like this:

$ pipenv install --system --dev --deploy
Installing dependencies from Pipfile.lock (5bec78)…
Ignoring idna-ssl: markers 'python_version < "3.7"' don't match your environment

[nothing at all for minutes, I have no idea if my ssh connection is broken, or pipenv hanged, or what... ]

showing download progress/ speed would be perfect, but I wold be also happy if i could see spinner like in npm or anything that would indicate that something is happening. I’m using version 2018.11.26

4reactions
lennonwoocommented, Jul 2, 2018

Thanks for your reply. I mean, sometimes when we want to install a big pypi package like pytorch (the pytorch’s .whl package size is 400+Mb), and one’s internet speed is slow (say 400Kb/s). In this situation, we need to wait about 17 minutes to finish downloading. During this time, the user cannot add options to pipenv to display package downloading speed or complete rate. The normal pipenv output to console during download pypi package is as follow:

$ pipenv install torch -v
Installing torch…
⠋Installing 'torch'
⠙$ "/home/lennon/.local/share/virtualenvs/test-yq5-nVUR/bin/pip" install   --verbose    "torch" -i https://pypi.org/simple --exists-action w
⠸

What I want is something like wget and pip’s progress-bar function.

say command $ wget https://pjreddie.com/media/files/yolov3.weights the wget will output to console the speed, complete rate, remain time to complete as follow:

--2018-07-02 20:19:50--  https://pjreddie.com/media/files/yolov3.weights
Loaded CA certificate '/etc/ssl/certs/ca-certificates.crt'
Resolving pjreddie.com (pjreddie.com)... 128.208.3.39
Connecting to pjreddie.com (pjreddie.com)|128.208.3.39|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 248007048 (237M) [application/octet-stream]
Saving to: ‘yolov3.weights’

yolov3.weights            0%[                               ] 455.70K  24.8KB/s    eta 2h 25m

And we can found the pip’s additional options in https://pip.pypa.io/en/stable/man/commands/install/?highlight=progress-bar#cmdoption-progress-bar when we use pip to download package, it will provide enough infomation for user about package downloading information. the pip’s output is something like wget:

$ pip install torch --progress-bar=on
Collecting torch
  Downloading https://files.pythonhosted.org/packages/69/43/380514bd9663f1bf708abeb359b8b48d3fabb1c8e95bb3427a980a064c57/torch-0.4.0-cp36-cp36m-manylinux1_x86_64.whl (484.0MB)
    0% |                                | 143kB 20kB/s eta 6:36:45

So, my suggestion is that maybe pipenv could provide a option mentioned previously. The user will know how long he could leave alone pipenv’s installation and handle other things.

Read more comments on GitHub >

github_iconTop Results From Across the Web

pipenv doesn't show progress bar when installing packages
If you are installing packages from PyPi (by default), a workaround is to first go to the "Download files" section of the package's...
Read more >
Advanced Usage of Pipenv - Python Packaging Authority
Pipenv makes an API call to retrieve those results and use them each time you run pipenv check to show you vulnerable dependencies....
Read more >
pipenv Documentation - Read the Docs
This tutorial walks you through installing and using Python packages. It will show you how to install and use the necessary tools and...
Read more >
Pipenv: promises a lot, delivers very little | Chris Warrick
Pipenv is a Python packaging tool that does one thing reasonably well. It tries to promote itself as much more than it is....
Read more >
tqdm - PyPI
If float(“inf”) or as a last resort, only basic progress statistics are displayed (no ETA, no progressbar). If gui is True and this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found