# ERROR: Cannot install package-a[extra1,extra2]==1.0 and package-b==2.0 because these package versions have conflicting dependencies. The conflict is caused by: package-a 1.0 depends on package-c>=3.0 and package-b 2.0 depends on package-c<3.0.

- **ID:** `pip/dependency-conflict-with-extras`
- **Domain:** pip
- **Category:** install_error
- **Error Code:** `ERROR`
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

Two requested packages have mutually exclusive version constraints on a shared dependency, and pip's resolver cannot find a version of the shared dependency that satisfies both constraints simultaneously.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| pip 23.2 | active | — | — |
| pip 24.1 | active | — | — |
| pip 24.2 | active | — | — |

## Workarounds

1. **Install an older version of package-a that depends on package-c<3.0: pip install 'package-a[extra1,extra2]<1.0' package-b==2.0** (75% success)
   ```
   Install an older version of package-a that depends on package-c<3.0: pip install 'package-a[extra1,extra2]<1.0' package-b==2.0
   ```
2. **Use a virtual environment and install package-c at a version that satisfies both (e.g., package-c==2.99), then install packages without dependencies: pip install package-c==2.99 && pip install --no-deps package-a[extra1,extra2]==1.0 package-b==2.0** (60% success)
   ```
   Use a virtual environment and install package-c at a version that satisfies both (e.g., package-c==2.99), then install packages without dependencies: pip install package-c==2.99 && pip install --no-deps package-a[extra1,extra2]==1.0 package-b==2.0
   ```
3. **Contact the package maintainers to relax version constraints or use a fork that resolves the conflict.** (30% success)
   ```
   Contact the package maintainers to relax version constraints or use a fork that resolves the conflict.
   ```

## Dead Ends

- **Force install both packages with --no-deps to skip dependency resolution** — While this allows installation, the conflicting dependency package-c will be missing or have an incompatible version, causing runtime ImportError or AttributeError. (85% fail)
- **Upgrade pip to the latest version hoping the resolver improves** — The conflict is fundamental to the version constraints; no resolver can satisfy mutually exclusive requirements unless constraints are relaxed. (70% fail)
