python
install_error
ai_generated
partial
ERROR: Cannot install package-a==1.0 and package-b==2.0 because these package versions have conflicting dependencies. The conflict is caused by: The user requested package-a==1.0 package-b 2.0 depends on package-a<1.0
ID: python/pip-resolution-too-deep-backtracking
80%Fix Rate
86%Confidence
0Evidence
2024-05-08First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 3.x | active | — | — | — |
Root Cause
The dependency graph is unsatisfiable: two pinned requirements transitively require incompatible versions of a shared package.
generic中文
依赖图无法满足:两个固定版本的需求传递性地要求共享包的互不兼容版本。
Workarounds
-
90% success
pip install 'package-a>=0.9,<1.0' 'package-b==2.0'
-
85% success
pip install --dry-run --report report.json package-a==1.0 package-b==2.0 python -m json.tool report.json | less
Dead Ends
Common approaches that don't work:
-
85% fail
Force install does not resolve version conflicts; pip still refuses to pick a solution.
-
70% fail
The legacy resolver may install an inconsistent set, leading to runtime ImportErrors later.
-
60% fail
Unpinned installs may still conflict on transitive constraints and reproduce the error.