From 6b715c7fb6223c8c3e6123a7c41ea447ca402740 Mon Sep 17 00:00:00 2001 From: Garry Tan Date: Fri, 12 Jun 2026 15:27:19 -0700 Subject: [PATCH] fix: operational-learning fixture copies lib/jsonl-store.ts with the bin MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit gstack-learnings-log imports $SCRIPT_DIR/../lib/jsonl-store.ts (hasInjection, v1.57.5.0) — copying only the bin scripts into the temp fixture broke the script with exit 1 since then. Latent because diff-based selection rarely runs this test; surfaced when hermetic-env.ts joined GLOBAL_TOUCHFILES and selected everything. Reproduced outside the hermetic env to confirm blame. Co-Authored-By: Claude Fable 5 --- test/skill-e2e-bws.test.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/skill-e2e-bws.test.ts b/test/skill-e2e-bws.test.ts index 956174117..7de74e293 100644 --- a/test/skill-e2e-bws.test.ts +++ b/test/skill-e2e-bws.test.ts @@ -192,13 +192,17 @@ Report the exact output — either "READY: " or "NEEDS_SETUP".`, run('git', ['add', '.']); run('git', ['commit', '-m', 'initial']); - // Copy bin scripts + // Copy bin scripts — preserving the bin/../lib layout: + // gstack-learnings-log imports $SCRIPT_DIR/../lib/jsonl-store.ts + // (hasInjection, added v1.57.5.0), so the lib must travel with the bin. const binDir = path.join(opDir, 'bin'); fs.mkdirSync(binDir, { recursive: true }); for (const script of ['gstack-learnings-log', 'gstack-slug']) { fs.copyFileSync(path.join(ROOT, 'bin', script), path.join(binDir, script)); fs.chmodSync(path.join(binDir, script), 0o755); } + fs.mkdirSync(path.join(opDir, 'lib'), { recursive: true }); + fs.copyFileSync(path.join(ROOT, 'lib', 'jsonl-store.ts'), path.join(opDir, 'lib', 'jsonl-store.ts')); // gstack-learnings-log will create the project dir automatically via gstack-slug