Files
pnpm/building
Zoltan Kochan ec6473e95e fix: align git-hosted store readers with the integrity-keyed writer
Once the lockfile pins integrity for git-hosted tarballs, every
post-fetch reader (pkg-finder, store status, FUSE mounter,
skipIfHasSideEffectsCache in building/after-install) looks the package
up under storeIndexKey(integrity, pkgId). Three issues were exposed:

1. pkg-finder ran parse(packageId) and rebuilt name@version, but
   packageIdFromSnapshot returns the URL alone for git-hosted (the
   `:` in `https://` makes tryGetPackageId strip the `name@`
   prefix). parse(URL) returns {} and the lookup key became
   `…\tundefined@undefined`. Use packageId directly — that's the
   form the writer in package-requester uses.

2. The FUSE handler and the after-install side-effects-cache lookup
   used `${name}@${version}`, which doesn't match the resolver's
   pkg.id for git-hosted (URL). Use
   `nonSemverVersion ?? ${name}@${version}` so the readers compute
   the same key the writer uses.

3. On the first install, integrity isn't known when
   getFilesIndexFilePath runs, so the writer parks the index under
   gitHostedStoreIndexKey. Once the worker computes integrity, the
   git-hosted fetcher now also registers the entry under
   storeIndexKey(integrity, pkgId), so subsequent integrity-based
   lookups (the same install or any later one) resolve to the same
   data without a refetch.

The license test that walks the lockfile right after install now
passes locally; that's the case that was failing in CI.

---
Written by an agent (Claude Code, claude-opus-4-7).
2026-05-06 02:00:36 +02:00
..
2026-05-05 19:50:32 +02:00
2026-05-05 19:50:32 +02:00
2026-04-30 23:03:46 +02:00
2026-05-05 19:50:32 +02:00