Skip to content

Commit 58fe47e

Browse files
NullVoxPopuliclaude
andcommitted
Fall back to non-frozen pnpm install for control dir
The frozen lockfile install can fail when the control branch's lockfile was generated with different pnpm settings. Fall back gracefully since exact reproducibility of the control's node_modules is less critical than being able to run the benchmark at all. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
1 parent e80a86b commit 58fe47e

1 file changed

Lines changed: 12 additions & 4 deletions

File tree

scripts/bench-compare.mjs

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,18 @@ try {
8888

8989
// ── 2. Install dependencies in control dir ───────────────────────────────
9090
console.error(`\n📦 Installing dependencies for control (${BASE_BRANCH})…\n`);
91-
run('pnpm install --frozen-lockfile', {
92-
cwd: CONTROL_DIR,
93-
stdio: ['inherit', 'pipe', 'inherit'],
94-
});
91+
try {
92+
run('pnpm install --frozen-lockfile', {
93+
cwd: CONTROL_DIR,
94+
stdio: ['inherit', 'pipe', 'inherit'],
95+
});
96+
} catch {
97+
console.error('⚠️ Frozen install failed, retrying without --frozen-lockfile…\n');
98+
run('pnpm install --no-frozen-lockfile', {
99+
cwd: CONTROL_DIR,
100+
stdio: ['inherit', 'pipe', 'inherit'],
101+
});
102+
}
95103

96104
// ── 3. Run mitata bench with --control-dir ───────────────────────────────
97105
console.error(`\n🏎️ Running benchmarks (experiment vs control)…\n`);

0 commit comments

Comments
 (0)