I am getting this dependency resolution error in pip 24 (from pip 23) about a dependency in one of my projects:
The conflict is caused by:
The user requested packageA
The user requested (constraint) packageA==1.0.0+f2ca1bb6c7e907d06dafe4687e579fce76b37e4e93b7605022da52e6ccc26fd2
The requirements.txt of one of my packages has listed in it’s requirements.txt packageA without a version meaning “any version will do” and as a constraint I list the current dev version of each package.
In previous versions of pip this worked as expected: the resolution is to prioritize the specific version of the package over the non-specific version of the package; instead of an error pip installs packageA==1.0.0+f2ca1bb6c7e907d06dafe4687e579fce76b37e4e93b7605022da52e6ccc26fd2
since that satisfies the requirement packageA
(any version). However after upgrading pip it is unable to resolve that scenario. Is there a new flag I’m missing or has there been a fundamental change to pip I’m unaware of?
To clarify, no packages in either requirements or constraints specify anything other than the package name and the package version (in the case of the contraints). There is no python_version
or anything extra like that.
Andrew Laramore is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.