Bump MSRV to 1.84 (#12670)

## Summary

Closes https://github.com/astral-sh/uv/issues/12649.
This commit is contained in:
Charlie Marsh 2025-04-04 11:49:26 -04:00 committed by GitHub
parent 420fc287fa
commit 42dcea0ee2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
64 changed files with 162 additions and 144 deletions

View file

@ -522,7 +522,7 @@ impl CandidateSelector {
}
if !range.contains(version) {
continue;
};
}
let Some(dist) = maybe_dist.prioritized_dist() else {
continue;
};

View file

@ -1459,7 +1459,7 @@ impl Lock {
return Ok(SatisfiesResult::MissingLocalIndex(name, version, path));
}
}
};
}
}
// If the package is immutable, we don't need to validate it (or its dependencies).
@ -2257,7 +2257,7 @@ impl Package {
}
.into()),
};
};
}
}
if let Some(sdist) = self.to_source_dist(workspace_root)? {
@ -3599,8 +3599,8 @@ impl GitSource {
"branch" => kind = GitSourceKind::Branch(val.into_owned()),
"rev" => kind = GitSourceKind::Rev(val.into_owned()),
"subdirectory" => subdirectory = Some(PortablePathBuf::from(val.as_ref()).into()),
_ => continue,
};
_ => {}
}
}
let precise = GitOid::from_str(url.fragment().ok_or(GitSourceError::MissingSha)?)
.map_err(|_| GitSourceError::InvalidSha)?;

View file

@ -1,4 +1,5 @@
use std::collections::{BTreeSet, VecDeque};
use std::fmt::Write;
use either::Either;
use itertools::Itertools;
@ -431,17 +432,17 @@ impl<'env> TreeDisplay<'env> {
if let Some(version) = package_id.version.as_ref() {
line.push(' ');
line.push('v');
line.push_str(&format!("{version}"));
let _ = write!(line, "{version}");
}
if let Some(edge) = edge {
match edge {
Edge::Prod(_) => {}
Edge::Optional(extra, _) => {
line.push_str(&format!(" (extra: {extra})"));
let _ = write!(line, " (extra: {extra})");
}
Edge::Dev(group, _) => {
line.push_str(&format!(" (group: {group})"));
let _ = write!(line, " (group: {group})");
}
}
}

View file

@ -188,7 +188,7 @@ impl PubGrubPriorities {
if matches!(entry.get(), PubGrubPriority::ConflictEarly(_)) {
// Already in the right category
return false;
};
}
let index = Self::get_index(&entry).unwrap_or(len);
entry.insert(PubGrubPriority::ConflictEarly(Reverse(index)));
true
@ -225,7 +225,7 @@ impl PubGrubPriorities {
) {
// Already in the right category
return false;
};
}
let index = Self::get_index(&entry).unwrap_or(len);
entry.insert(PubGrubPriority::ConflictLate(Reverse(index)));
true

View file

@ -711,7 +711,7 @@ impl PubGrubReportFormatter<'_> {
output_hints,
);
}
};
}
}
/// Generate a [`PubGrubHint`] for a package that doesn't have any wheels matching the current
@ -1957,7 +1957,7 @@ impl std::fmt::Display for PackageRange<'_> {
(Bound::Excluded(v), Bound::Unbounded) => write!(f, "{package}>{v}")?,
(Bound::Excluded(v), Bound::Included(b)) => write!(f, "{package}>{v},<={b}")?,
(Bound::Excluded(v), Bound::Excluded(b)) => write!(f, "{package}>{v},<{b}")?,
};
}
}
if segments.len() > 1 {
writeln!(f)?;
@ -2015,7 +2015,7 @@ impl std::fmt::Display for DependsOn<'_> {
write!(f, "depend on ")?;
} else {
write!(f, "depends on ")?;
};
}
match self.dependency2 {
Some(ref dependency2) => write!(

View file

@ -1363,7 +1363,7 @@ impl<InstalledPackages: InstalledPackagesProvider> ResolverState<InstalledPackag
// packages that include a source distribution), we don't need to fork.
if dist.implied_markers().is_true() {
return Ok(None);
};
}
// If the user explicitly marked a platform as required, ensure it has coverage.
for marker in self.options.required_environments.iter().copied() {
@ -2813,7 +2813,7 @@ impl ForkState {
.partial_solution
.add_decision(self.next, version);
return;
};
}
self.pubgrub
.add_incompatibility(Incompatibility::custom_version(
self.next,

View file

@ -68,7 +68,7 @@ impl Urls {
debug!("Allowing an editable variant of {}", &package_url.verbatim);
*editable = true;
}
};
}
}
} else {
package_urls.push(url);