From 0b92af95c39b4219505412ba7dcb5ff28a52260f Mon Sep 17 00:00:00 2001 From: Ruben Arts Date: Fri, 12 Jan 2024 10:22:08 +0100 Subject: [PATCH] fix: Check for pypi-dependencies before ammending the pypi purls (#661) --- src/lock_file/mod.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/lock_file/mod.rs b/src/lock_file/mod.rs index e5b35c1ef..bbcb3ce90 100644 --- a/src/lock_file/mod.rs +++ b/src/lock_file/mod.rs @@ -339,8 +339,10 @@ async fn resolve_platform( ) .await?; - // Add purl's for the conda packages that are also available as pypi packages - pypi::amend_pypi_purls(&mut records).await?; + // Add purl's for the conda packages that are also available as pypi packages if we need them. + if project.manifest.has_pypi_dependencies() { + pypi::amend_pypi_purls(&mut records).await?; + } // Update lock file let mut locked_packages = LockedPackagesBuilder::new(platform);