Skip to content

Commit

Permalink
fix(resolver): Don't report all versions as rejected
Browse files Browse the repository at this point in the history
When I copy/pasted the alternative-names code, I didn't notice that the
wildcard dependency was used.

This does not have a test yet because overly-constrictive dep specs have
higher precedence atm (which I plan to also fix).
  • Loading branch information
epage committed Dec 11, 2024
1 parent 8ec9b1e commit 3aab145
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cargo/core/resolver/errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ pub(super) fn activation_error(
} else {
// Maybe something is wrong with the available versions
let mut version_candidates = loop {
match registry.query_vec(&wild_dep, QueryKind::RejectedVersions) {
match registry.query_vec(&dep, QueryKind::RejectedVersions) {
Poll::Ready(Ok(candidates)) => break candidates,
Poll::Ready(Err(e)) => return to_resolve_err(e),
Poll::Pending => match registry.block_until_ready() {
Expand Down

0 comments on commit 3aab145

Please sign in to comment.