From 17883e15293b7f09201c85659e9009b12a1ade90 Mon Sep 17 00:00:00 2001 From: CRT Date: Wed, 14 Oct 2026 08:33:12 +0800 Subject: [PATCH] acceptance: create the --out folder (both CI runs passed every quick cell, then failed writing acceptance/.json), log the warm-up cell --- tools/acceptance.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tools/acceptance.ts b/tools/acceptance.ts index 0abb5ee..b197288 100644 --- a/tools/acceptance.ts +++ b/tools/acceptance.ts @@ -466,7 +466,11 @@ async function run(argv: string[]): Promise { // warm up: the first npx / bun x call installs the tarball; run it alone so parallel cells do not race the cache const queue = [...list]; const first = queue.findIndex(c => c.id === '--version'); - if (first >= 0) results.push(await runCell(queue.splice(first, 1)[0]!, rt, mock.base, tpl, home, platform, running)); + if (first >= 0) { + const r = await runCell(queue.splice(first, 1)[0]!, rt, mock.base, tpl, home, platform, running); + console.log(`${r.ok ? 'ok ' : 'FAIL'} ${r.id} (${r.ms} ms, installs the tarball)${r.error ? `: ${r.error}` : ''}`); + results.push(r); + } let stopped = false; const budget = setTimeout(() => { stopped = true; console.log(`acceptance: budget of ${budgetMs / 60_000} min used up; killing the running cells`); }, budgetMs); await Promise.all(Array.from({ length: jobs }, async () => { @@ -484,6 +488,7 @@ async function run(argv: string[]): Promise { results.sort((a, b) => (order.get(a.id) ?? 0) - (order.get(b.id) ?? 0)); const failed = results.filter(r => !r.ok); const out = resolve(arg('--out') ?? join(ROOT, `acceptance-${platform}-${rt.name.replace(/\s+/g, '')}.json`)); + mkdirSync(dirname(out), { recursive: true }); writeFileSync(out, JSON.stringify({ platform, runtime: rt.name, label: rt.label, version: PKG.version, quick, at: new Date().toISOString(), results }, null, 2)); console.log(`acceptance: ${results.length - failed.length}/${results.length} cells passed in ${Math.round((Date.now() - t0) / 1000)} s -> ${out}`); if (failed.length) {