diff --git a/crates/pet-core/src/os_environment.rs b/crates/pet-core/src/os_environment.rs index 6fa0b44f..f9ef61a3 100644 --- a/crates/pet-core/src/os_environment.rs +++ b/crates/pet-core/src/os_environment.rs @@ -50,7 +50,6 @@ impl Environment for EnvironmentApi { if self.global_search_locations.lock().unwrap().is_empty() { let mut paths = env::split_paths(&self.get_env_var("PATH".to_string()).unwrap_or_default()) - .into_iter() .filter(|p| p.exists()) .collect::>(); trace!("Env PATH: {:?}", paths); diff --git a/crates/pet-windows-registry/src/environments.rs b/crates/pet-windows-registry/src/environments.rs index a2139be3..c10cfc34 100644 --- a/crates/pet-windows-registry/src/environments.rs +++ b/crates/pet-windows-registry/src/environments.rs @@ -101,7 +101,7 @@ fn get_registry_pythons_from_key_for_company( Ok(install_path_key) => { let env_path: String = install_path_key.get_value("").ok().unwrap_or_default(); - let env_path = norm_case(&PathBuf::from(env_path)); + let env_path = norm_case(PathBuf::from(env_path)); if is_windows_app_folder_in_program_files(&env_path) { trace!( "Found Python ({}) in {}\\Software\\Python\\{}\\{}, but skipping as this is a Windows Store Python", @@ -144,7 +144,7 @@ fn get_registry_pythons_from_key_for_company( ); continue; } - let executable = norm_case(&PathBuf::from(executable)); + let executable = norm_case(PathBuf::from(executable)); if !executable.exists() { warn!( "Python executable ({}) file not found for {}\\Software\\Python\\{}\\{}", diff --git a/crates/pet-windows-store/src/environments.rs b/crates/pet-windows-store/src/environments.rs index 6955dc8b..2d520e52 100644 --- a/crates/pet-windows-store/src/environments.rs +++ b/crates/pet-windows-store/src/environments.rs @@ -32,6 +32,7 @@ lazy_static! { } #[derive(Default)] +#[allow(dead_code)] struct PotentialPython { #[allow(dead_code)] path: Option, diff --git a/crates/pet-windows-store/src/lib.rs b/crates/pet-windows-store/src/lib.rs index 4d6f70b4..233974c3 100644 --- a/crates/pet-windows-store/src/lib.rs +++ b/crates/pet-windows-store/src/lib.rs @@ -74,7 +74,7 @@ impl Locator for WindowsStore { } let list_of_possible_exes = vec![env.executable.clone()] .into_iter() - .chain(env.symlinks.clone().unwrap_or_default().into_iter()) + .chain(env.symlinks.clone().unwrap_or_default()) .collect::>(); if let Some(environments) = self.find_with_cache() { for found_env in environments { diff --git a/crates/pet/src/locators.rs b/crates/pet/src/locators.rs index 1a6fdd7c..3047217d 100644 --- a/crates/pet/src/locators.rs +++ b/crates/pet/src/locators.rs @@ -200,6 +200,7 @@ fn find_symlinks(executable: &PathBuf) -> Option> { } #[cfg(windows)] +#[allow(clippy::ptr_arg)] fn find_symlinks(_executable: &PathBuf) -> Option> { // In windows we will need to spawn the Python exe and then get the exes. // Lets wait and see if this is necessary.