fix: don't read from side-effects cache packages that aren't allowed to be built (#9047)

close #9042
This commit is contained in:
Zoltan Kochan
2025-02-06 00:12:54 +01:00
committed by GitHub
parent afbb65495e
commit 9843aedd76
2 changed files with 9 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
---
"@pnpm/headless": patch
"@pnpm/build-modules": patch
"@pnpm/core": patch
"pnpm": patch
---
Don't read a package from side-effects cache if it isn't allowed to be built [#9042](https://github.com/pnpm/pnpm/issues/9042).

View File

@@ -395,6 +395,7 @@ async function linkNewPackages (
optional: opts.optional,
}),
linkAllPkgs(opts.storeController, newPkgs, {
allowBuild: opts.allowBuild,
depGraph,
depsStateCache: opts.depsStateCache,
disableRelinkLocalDirDeps: opts.disableRelinkLocalDirDeps,