Skip to content

unsuccessful solve should show origins of conflicting dependencies #3405

Open
@savente93

Description

@savente93

Checks

  • I have checked that this issue has not already been reported.

  • I have confirmed this bug exists on the latest version of pixi, using pixi --version.

(it is arguable that this is a feature request and not a bug, but since it involved a MWE I reported as such. Maintainers are free to convert it to feature request if they think that is better)

Reproducible example

pixi init
pixi add gdal==*
pixi add numpy<2.2 --pypi

this outputs

> pixi add numpy<2.2 --pypi
Error:   × failed to solve the pypi requirements of 'default' 'win-64'                                                                                           
  ├─▶ failed to resolve pypi dependencies                                                                                                                        
  ╰─▶ Because you require numpy<2.2 and numpy==2.2.4, we can conclude that your requirements are unsatisfiable.

Issue description

The issue above is that numpy==2.2.4 is a pinned transitive dependency from gdal but not specified in the manifest which left me really quite confused when I encountered it in a larger project. This made it very difficult to find out where this dependency came from.

perhaps this is also connected to #3093 (not sure, tagging just in case)

Expected behavior

The solve should hint at where the dependency comes from. In some cases this seems to happen but not always. (I suspect that uv does this, but because this MWE mixes pypi and conda dependencies it does not happen, though I can't be sure)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions