Skip to content

Reason for missing releases in solution #1127

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

Merged
merged 4 commits into from
Aug 18, 2022

Conversation

mosteo
Copy link
Member

@mosteo mosteo commented Aug 1, 2022

This is an internal improvement to the solver so now when a dependency can't be solved it will give the reason (via an extra :reason part after the usual missed). For example, in the output of alr with --solve:

Dependencies (external):
   hello(=1.0) & (=1.0.1) (direct,missed:conflict)
   libhello^777 (direct,missed:unavailable)
   unobtanium* (direct,missed:unindexed)
Dependencies (graph):
   some_dep=0.1.0-dev --> hello=1.0.1 
   xxx=0.1.0-dev      --> hello=1.0    
   xxx=0.1.0-dev      --> libhello^777
   xxx=0.1.0-dev      --> unobtanium*
  • Unindexed: the crate doesn't exist at all in our indexes
  • Unavailable: the requested version does not exist (but the crate does)
  • Conflict: two dependencies on the same crate cannot be reconciled. This can be further diagnosed in the graph portion of the solution (no change on the info shown there).

mosteo added 3 commits August 1, 2022 14:28
Although other tests already exercise the new feature, this way we have an
explicit one in case the others changed at some point.
@mosteo mosteo marked this pull request as ready for review August 2, 2022 08:58
@mosteo mosteo requested a review from Fabien-Chouteau August 2, 2022 08:58
Copy link
Member

@Fabien-Chouteau Fabien-Chouteau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me except for the word "unindexed". To me it feels like the crate is available somewhere but not indexed, which might not be the case. Maybe "unknown" would be better.

@mosteo
Copy link
Member Author

mosteo commented Aug 18, 2022

I see your point. Will change it.

@mosteo mosteo merged commit 5b55126 into alire-project:master Aug 18, 2022
@mosteo mosteo deleted the feat/missing-reasons branch August 18, 2022 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants