-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't fail on packages during dependency resolution #11212
Comments
This behavior is intentional, you can see the discussion and reasoning here: #10655 and the relevant pull requests #10722 But in summary:
If you read in to the discussions I was definitely one of the voices who was skeptical of this change thinking it would cause a large user outcry. I'm happy to say that, as far as I know, few people seem to have complained. |
I have a similar issue with a shorter list of packages
this worked perfectly fine until the new backtracking was implemented. My only way to resolve this is to use pip-tools to compile the dependencies, then set those versions as constraints. Not sure how much longer this will work. From a user perspective, this new dependency resolution definitely feels like a step backwards. It's much slower in general, too. |
Using constraints is the recommended way to supply the correct user intent and will continue to work for the foreseeable future. I’m going to close this since failing on a package is an intentional design decision. If you are interested in history, the resolver actually used to do what is requested in this issue (skip failed packages) when it was first implemented, but it generated a pretty significant number of users wanting this changed, so we changed it. If I remember correctly, there are less than a handful of reports wanting the “old” behaviour, so IMO the current design is likely the correct choice. I also want to mention that if a certain version of a package can’t correctly build on your working environment, it is likely you don’t want that version in the first place, and you should express that in your requirements with version constraints such as |
Description
If you give pip a large enough
requirements.txt
with no direct version constraints, it sooner or later will go berserk and try to download/parse all versions.This means it will run into all kinds of issues where the
setup.py
fails to execute, either because language incompatibilty or other stuff, like deprecatedsetuptools
features (for eg. https://setuptools.pypa.io/en/latest/history.html#v58-0-0).So instead of dying and breaking the whole process, wouldn't it better to just skip those packages, whose
setup.py
couldn't run?We won't be able to install them anyways, right?
Expected behavior
I would expect that if there is a compatible mix of packages, pip should be able to actually find out a working version list and not fail on multi-year packages, which aren't able to run anyways.
pip version
22.1.2
Python version
3.8.10
OS
Ubuntu 20.04.4 LTS
How to Reproduce
Give pip this list:
It will eventually die with
or this:
Or anything like those...
Output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: