From 2eba52f6749d87bf6041964fdf7550eadbd8bdee Mon Sep 17 00:00:00 2001 From: Charlie Marsh Date: Thu, 2 Jan 2025 11:40:48 -0500 Subject: [PATCH] Avoid forking on version in non-universal resolutions (#10274) ## Summary Closes https://github.com/astral-sh/uv/issues/10275. --- crates/uv-resolver/src/resolver/mod.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/crates/uv-resolver/src/resolver/mod.rs b/crates/uv-resolver/src/resolver/mod.rs index 7873a44e0..e57bc54e1 100644 --- a/crates/uv-resolver/src/resolver/mod.rs +++ b/crates/uv-resolver/src/resolver/mod.rs @@ -1328,6 +1328,11 @@ impl ResolverState, ) -> Result, ResolveError> { + // This only applies to universal resolutions. + if env.marker_environment().is_some() { + return Ok(None); + } + // For now, we only apply this to local versions. if !candidate.version().is_local() { return Ok(None);