Skip to content

Commit

Permalink
Omit variant when detecting compatible Python installs
Browse files Browse the repository at this point in the history
  • Loading branch information
charliermarsh committed Jan 17, 2025
1 parent 08da17d commit e8a0bd2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions crates/uv-python/src/managed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -242,16 +242,16 @@ impl ManagedPythonInstallations {
pub fn find_matching_current_platform(
&self,
) -> Result<impl DoubleEndedIterator<Item = ManagedPythonInstallation>, Error> {
let platform_key = platform_key_from_env()?;
let os = Os::from_env();
let arch = Arch::from_env();
let libc = Libc::from_env()?;

let iter = ManagedPythonInstallations::from_settings(None)?
.find_all()?
.filter(move |installation| {
installation
.path
.file_name()
.map(OsStr::to_string_lossy)
.is_some_and(|filename| filename.ends_with(&platform_key))
installation.key.os == os
&& installation.key.arch.family == arch.family
&& installation.key.libc == libc
});

Ok(iter)
Expand Down

0 comments on commit e8a0bd2

Please sign in to comment.