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 fails to install all my packages, and then installs all of them

See original GitHub issue

Hi, it might be something that I do not understand or so. I have 2 sources specified and none of them is official pypi, but mirrors, so here is my Pipfile:

[[source]]

url = "https://company/api/pypi/pypi.python.org/simple"
verify_ssl = true
name = "pypi"


[[source]]

url = "https://company/api/pypi/pypi-local/simple"
verify_ssl = true
name = "pypi-local"


[packages]

cachetools = "==2.0.1"
click = "==6.2"
data-object = "==1.2.1"
flask-cache = "==0.13.1"
flask-classy = "==0.6.10"
flask-humanize = "==0.3.0"
flask-migrate = "==2.1.1"
flask-oauthlib = "==0.9.4"
flask-sqlalchemy = "==2.3.2"
flask-wtf = "==0.14.2"
flask = "==0.12.2"
huey = "==1.6.0"
pendulum = "==1.4.0"
pyyaml = "==3.12"
redis = "==2.10.6"
requests = "==2.18.4"
requests-cache = "==0.4.13"
sqlalchemy = "==1.2.1"
whitenoise = "==3.3.1"
gunicorn = "==19.7.1"


[dev-packages]

ipdb = "*"
ipython = "*"
flask-shell-ipython = "*"
coverage = "*"
flake8 = "*"
flask-debugtoolbar = "*"
Describe your environment
  1. OS Type Ubuntu
  2. Python version: $ python -V Python 3.6.1
  3. Pipenv version: $ pipenv --version pipenv, version 9.0.3
Expected result

All packages installed immediatly.

Actual result
Installing dependencies from Pipfile.lock (7e9249)…
An error occurred while installing blinker==1.4! Will try again.
An error occurred while installing click==6.2! Will try again.
An error occurred while installing coverage==4.4.2! Will try again.
An error occurred while installing decorator==4.2.1! Will try again.
An error occurred while installing flask-debugtoolbar==0.10.1! Will try again.
An error occurred while installing flask-shell-ipython==0.3.0! Will try again.
An error occurred while installing ipdb==0.10.3! Will try again.
An error occurred while installing ipython==6.2.1! Will try again.
An error occurred while installing ipython-genutils==0.2.0! Will try again.
An error occurred while installing jedi==0.11.1! Will try again.
An error occurred while installing parso==0.1.1! Will try again.
An error occurred while installing pexpect==4.3.1; sys_platform != 'win32'! Will try again.
An error occurred while installing pickleshare==0.7.4! Will try again.
An error occurred while installing prompt-toolkit==1.0.15! Will try again.
An error occurred while installing ptyprocess==0.5.2! Will try again.
An error occurred while installing pygments==2.2.0! Will try again.
An error occurred while installing simplegeneric==0.8.1! Will try again.
An error occurred while installing traitlets==4.3.2! Will try again.
An error occurred while installing wcwidth==0.1.7! Will try again.
Installing initially–failed dependencies…
Success installing blinker==1.4!
Success installing click==6.7!
Success installing coverage==4.4.2!
Success installing decorator==4.2.1!
Success installing flask-debugtoolbar==0.10.1!
Success installing flask-shell-ipython==0.3.0!
Success installing ipdb==0.10.3!
Success installing ipython==6.2.1!
Success installing ipython-genutils==0.2.0!
Success installing jedi==0.11.1!
Success installing parso==0.1.1!
Success installing pexpect==4.3.1; sys_platform != 'win32'!
Success installing pickleshare==0.7.4!
Success installing prompt-toolkit==1.0.15!
Success installing ptyprocess==0.5.2!
Success installing pygments==2.2.0!
Success installing simplegeneric==0.8.1!
Success installing traitlets==4.3.2!
Success installing wcwidth==0.1.7!
Steps to replicate

pipenv install --system Please also note, that pipenv is installing click==6.7 despite specifying 6.2 version.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:71
  • Comments:59 (17 by maintainers)

github_iconTop GitHub Comments

122reactions
kennethreitzcommented, Feb 17, 2018

closing since they are successful in the end — we’ll need much more information in order to replicate

68reactions
changyuhengcommented, Aug 29, 2019

Hi @jacekjab sorry you are running into this – the initial failure isn’t actually a bug, per se, I’m guessing it is related to concurrent installs from a non-pypi repository. They initially failed and then fell back to sequential installation. As far as the click installation, you will need to provide the full context of the command you ran, your $PATH, the output of env, that stuff would help

so the issue here is just that you are installing a bunch of VCS dependencies without using editable = true – many thanks @hjwp for the reproduction case

I believe I have a fix for this, although for the specific case you provided there will always be a single failure that will have to get pushed off till the end due to an editable dependency that needs to be installed after another dependency (you can avoid this with --sequential or by making the failing dependency editable)

Hi @techalchemy, thank you and you’re right, it’s due to some sort of conflicts related to the concurrent installation. However, making those dependencies editable didn’t solve the issue for me.

For people TL;DR, just add --sequential to your installation command, such as one of the following lines:

pipenv install --sequential
pipenv install --sequential -e .
pipenv sync --sequential
Read more comments on GitHub >

github_iconTop Results From Across the Web

Common Pipenv Errors and How to Solve Them: Why Won't it ...
The second most common reason locking fails is that we attempt to install a package that is a pre-release version. You can resolve...
Read more >
Pipenv install does not install everything from Pipfile
I just freshly installed pyenv and then Python 3.7.8 and pipenv, I installed it via pip, and i see no way that the...
Read more >
Frequently Encountered Pipenv Problems - Read the Docs
This is usually a result of mixing Pipenv with system packages. We strongly recommend installing Pipenv in an isolated environment. Uninstall all existing ......
Read more >
pipenv Documentation - Read the Docs
Pipenv is a tool that aims to bring the best of all packaging worlds ... In this approach, Pipenv in installed in the...
Read more >
Advanced Usage of Pipenv - Python Packaging Authority
All unspecified packages are resolved using the default index source; the default package index is PyPI. For a specific package to be installed...
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