fix: scope Npm.add() lock to per-package key

Use npm-install:${pkg} instead of a global npm-install lock so
concurrent installs of different packages can run in parallel.
This commit is contained in:
Dax Raad
2026-03-19 21:49:22 -04:00
parent ca2099e69d
commit 34c676ba7a

View File

@@ -56,7 +56,7 @@ export namespace Npm {
}
export async function add(pkg: string) {
using _ = await Lock.write("npm-install")
using _ = await Lock.write(`npm-install:${pkg}`)
log.info("installing package", {
pkg,
})