@pnpm/building.after-install 1101.0.20 → 1102.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,7 @@ export type StrictBuildOptions = {
18
18
  scriptsPrependNodePath: boolean | 'warn-only';
19
19
  shellEmulator: boolean;
20
20
  skipIfHasSideEffectsCache?: boolean;
21
+ frozenStore?: boolean;
21
22
  storeDir: string;
22
23
  storeController: StoreController;
23
24
  force: boolean;
package/lib/index.js CHANGED
@@ -20,7 +20,7 @@ import { logger, streamParser } from '@pnpm/logger';
20
20
  import npa from '@pnpm/npm-package-arg';
21
21
  import { safeReadPackageJsonFromDir } from '@pnpm/pkg-manifest.reader';
22
22
  import { createStoreController } from '@pnpm/store.connection-manager';
23
- import { pickStoreIndexKey, StoreIndex } from '@pnpm/store.index';
23
+ import { pickStoreIndexKey, ReadOnlyStoreIndex, StoreIndex } from '@pnpm/store.index';
24
24
  import { hardLinkDir } from '@pnpm/worker';
25
25
  import pLimit from 'p-limit';
26
26
  import { runGroups } from 'run-groups';
@@ -243,7 +243,16 @@ async function _rebuild(ctx, opts) {
243
243
  return false;
244
244
  };
245
245
  const builtDepPaths = new Set();
246
- const storeIndex = opts.skipIfHasSideEffectsCache ? new StoreIndex(opts.storeDir) : undefined;
246
+ // This handle is read-only in practice (only `.get()` below); the
247
+ // side-effects upload writes through `storeController`, not here. Open it
248
+ // immutable under `frozenStore` so the read works against a read-only store
249
+ // — a writable open would fail creating the WAL/`-shm` sidecar there. The
250
+ // immutable open is gated on `frozenStore` because on a normal install the
251
+ // concurrent side-effects uploads mutate `index.db`, which immutable reads
252
+ // would not see.
253
+ const storeIndex = opts.skipIfHasSideEffectsCache
254
+ ? (opts.frozenStore ? new ReadOnlyStoreIndex(opts.storeDir) : new StoreIndex(opts.storeDir))
255
+ : undefined;
247
256
  // Under GVS, packages live at `<globalVirtualStoreDir>/<hash>/node_modules/<name>`,
248
257
  // not the classic virtualStoreDir layout. The hash is computed with the same inputs
249
258
  // as the installer so rebuild resolves the exact directory the install created.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pnpm/building.after-install",
3
- "version": "1101.0.20",
3
+ "version": "1102.0.0",
4
4
  "description": "Rebuild packages that are already installed by running their lifecycle scripts",
5
5
  "keywords": [
6
6
  "pnpm",
@@ -32,38 +32,38 @@
32
32
  "load-json-file": "^7.0.1",
33
33
  "p-limit": "^7.3.0",
34
34
  "run-groups": "^5.0.0",
35
- "semver": "^7.8.1",
36
- "@pnpm/bins.linker": "1100.0.12",
37
- "@pnpm/building.policy": "1100.0.9",
38
- "@pnpm/config.reader": "1101.7.0",
39
- "@pnpm/core-loggers": "1100.1.4",
40
- "@pnpm/deps.graph-hasher": "1100.2.4",
35
+ "semver": "^7.8.4",
36
+ "@pnpm/building.pkg-requires-build": "1100.0.8",
37
+ "@pnpm/building.policy": "1100.0.10",
38
+ "@pnpm/bins.linker": "1100.0.14",
39
+ "@pnpm/config.reader": "1101.9.0",
40
+ "@pnpm/core-loggers": "1100.2.1",
41
+ "@pnpm/deps.graph-hasher": "1100.2.5",
42
+ "@pnpm/config.normalize-registries": "1100.0.8",
41
43
  "@pnpm/deps.graph-sequencer": "1100.0.0",
42
- "@pnpm/constants": "1100.0.0",
43
- "@pnpm/exec.lifecycle": "1100.0.16",
44
+ "@pnpm/deps.path": "1100.0.8",
44
45
  "@pnpm/error": "1100.0.0",
45
- "@pnpm/deps.path": "1100.0.7",
46
- "@pnpm/installing.context": "1100.0.16",
47
- "@pnpm/lockfile.utils": "1100.0.12",
48
- "@pnpm/lockfile.types": "1100.0.10",
49
- "@pnpm/pkg-manifest.reader": "1100.0.7",
50
- "@pnpm/config.normalize-registries": "1100.0.7",
51
- "@pnpm/store.connection-manager": "1100.2.7",
52
- "@pnpm/store.cafs": "1100.1.9",
53
- "@pnpm/store.controller-types": "1100.1.4",
54
- "@pnpm/types": "1101.3.1",
55
- "@pnpm/installing.modules-yaml": "1100.0.8",
56
- "@pnpm/store.index": "1100.1.0",
57
- "@pnpm/building.pkg-requires-build": "1100.0.7",
58
- "@pnpm/lockfile.walker": "1100.0.10"
46
+ "@pnpm/exec.lifecycle": "1100.0.18",
47
+ "@pnpm/installing.context": "1100.0.18",
48
+ "@pnpm/constants": "1100.0.0",
49
+ "@pnpm/lockfile.walker": "1100.0.11",
50
+ "@pnpm/installing.modules-yaml": "1100.0.9",
51
+ "@pnpm/lockfile.utils": "1100.0.13",
52
+ "@pnpm/pkg-manifest.reader": "1100.0.8",
53
+ "@pnpm/lockfile.types": "1100.0.11",
54
+ "@pnpm/store.connection-manager": "1100.3.0",
55
+ "@pnpm/store.cafs": "1100.1.10",
56
+ "@pnpm/store.controller-types": "1100.1.5",
57
+ "@pnpm/store.index": "1100.2.0",
58
+ "@pnpm/types": "1101.3.2"
59
59
  },
60
60
  "peerDependencies": {
61
- "@pnpm/logger": "^1001.0.1",
62
- "@pnpm/worker": "^1100.1.10"
61
+ "@pnpm/logger": "^1100.0.0",
62
+ "@pnpm/worker": "^1100.2.0"
63
63
  },
64
64
  "devDependencies": {
65
65
  "@types/semver": "7.7.1",
66
- "@pnpm/building.after-install": "1101.0.20"
66
+ "@pnpm/building.after-install": "1102.0.0"
67
67
  },
68
68
  "engines": {
69
69
  "node": ">=22.13"