From 13167232697a681f7ab227bd66611f8b0fa56e2d Mon Sep 17 00:00:00 2001 From: Dotta Date: Tue, 3 Nov 2026 19:17:04 -0600 Subject: [PATCH] test: retain self-contained process regression fixture --- .../live-ce33-914/README.md | 2 ++ .../verify-birth-settlement-before.source.txt | 21 +++++++++++++++++++ .../live-ce33-914/manifest.json | 13 ++++++++---- .../live-ce33-914/verification-follow-up.json | 10 +++++++-- .../native-ingestion/live-process-check.mjs | 3 +-- 5 files changed, 41 insertions(+), 8 deletions(-) create mode 100644 doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/helpers/verify-birth-settlement-before.source.txt diff --git a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/README.md b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/README.md index 236d8d3b55e..e15a1639f59 100644 --- a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/README.md +++ b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/README.md @@ -25,3 +25,5 @@ The old selector returned an empty array atcall120 because the live interstitial Resource-specific absolute checkout/evidence/temporary-home paths were replaced with descriptive references. `public-projections.json` records original and public hashes for each projection. Revisions, event identities, times, counts, hashes, cleanup outcomes and limits are unchanged. The launcher retains its already published generic macOS temporary-directory prefix, not a resource-specific private path. The two argument-adapted monitor/checker copies were syntax checked only; original executed hashes remain distinct. Run the future offline verification explicitly with `node --test scripts/native-ingestion/live-browser-streaming-check.mjs`; it is an opt-in Node/Playwright check outside the current default Vitest projects. The original22-file proof bundle remains unchanged. The reviewed follow-up also accepts OpenCode ordinary deltas without an artificial `item.started` prerequisite while retaining explicit completion/finalization/terminal rejection. The birth-settlement reproduction helper now requires one successful complete process-list snapshot and propagates command failures. `verification-follow-up.json` records the offline regressions; `independent-successful-process-snapshot.json` separately selects the original successful monitor output for all four captured process identities. These corrected helpers were not executed in a new live journey. + +The faulty pre-fix process checker is archived as `helpers/verify-birth-settlement-before.source.txt` solely for the offline regression. It is source text, not a reproduction command. The regression reads this committed fixture without invoking Git or requiring the original commit, so shallow and squashed checkouts remain reproducible. diff --git a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/helpers/verify-birth-settlement-before.source.txt b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/helpers/verify-birth-settlement-before.source.txt new file mode 100644 index 00000000000..d763287aa23 --- /dev/null +++ b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/helpers/verify-birth-settlement-before.source.txt @@ -0,0 +1,21 @@ +import assert from 'node:assert/strict'; +import {readFile,writeFile} from 'node:fs/promises'; +import {execFileSync} from 'node:child_process'; +import path from 'node:path'; +const directory=process.argv[2]; +if (!directory) throw new Error('Pass the owned evidence directory'); +const browser=JSON.parse(await readFile(path.join(directory,'live-provider-result.json'),'utf8')); +const stop=browser.journeys.find(journey=>journey.kind==='stop-live-provider'); +const gate=stop.preStopProcessProof; +assert.equal(stop.status,'passed');assert.ok(gate.verifiedBeforeClickAtMs<=stop.requestedAt); +assert.equal(gate.runId,stop.activeRunId);assert.equal(gate.command,'sleep 60'); +assert.ok(gate.observedProcessAgeMs+gate.verifiedBeforeClickAtMs-gate.observedAtMs<20000); +assert.equal(gate.chain[0].pid,gate.sleepPid);assert.equal(gate.chain.at(-1).pid,gate.runnerPid); +assert.ok(gate.chain.some(proc=>/verified-executable|opencode/.test(proc.executable))); +const checks=gate.chain.map(proc=>{ + let text='';try{text=execFileSync('ps',['-p',String(proc.pid),'-o','pid=,ppid=,stat=,lstart=,comm='],{encoding:'utf8',stdio:['ignore','pipe','ignore']}).trim();}catch{} + assert.equal(text,'','Exact owned birth PID remains present after settlement'); + return {pid:proc.pid,observedBirthTime:proc.birthTime,observedExecutable:proc.executable,absent:true}; +}); +const output={verified:true,checkedAt:new Date().toISOString(),runId:gate.runId,causalOrder:'Owned live sleep60 birth identity gate completed before ordinary UI Stop click',source:'Independent postsettlement ps by exact preStop birth-identity chain',checks}; +await writeFile(path.join(directory,'independent-birth-settlement-proof.json'),JSON.stringify(output,null,2));console.log(JSON.stringify(output,null,2)); diff --git a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/manifest.json b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/manifest.json index 686776b98d6..3632a1506b7 100644 --- a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/manifest.json +++ b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/manifest.json @@ -7,8 +7,8 @@ "files": [ { "path": "README.md", - "bytes": 7357, - "sha256": "349c8a64444f41f06942959950afd0f480c724ee539e8a8b76523be5a3481050" + "bytes": 7696, + "sha256": "67aca55715fd0553e13637b159b79854c85dfdae236fd0308e68dd896093ca1d" }, { "path": "after-live-stop.png", @@ -90,6 +90,11 @@ "bytes": 4858, "sha256": "bc06e6797f7189a4d56b09ec268de3f59267e7ed7082f37f3aab3f4d784bc1e6" }, + { + "path": "helpers/verify-birth-settlement-before.source.txt", + "bytes": 1752, + "sha256": "3eca4c0bd960e87225fee9c74a6f9ef0eb785b3d3766bc8435900aaa266d4d46" + }, { "path": "helpers/verify-birth-settlement.mjs", "bytes": 2308, @@ -167,8 +172,8 @@ }, { "path": "verification-follow-up.json", - "bytes": 1676, - "sha256": "1c87e25e957f032ac3462441a8b20a6ca07985bf5e0e396fed8e49c1596f36ff" + "bytes": 2077, + "sha256": "0a917de1efb6664121eafd899dcd21d0464714098c88b1b18f72ff74cdc16c09" } ] } diff --git a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/verification-follow-up.json b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/verification-follow-up.json index 5f8ab7c96fc..3e7d4ba3ebb 100644 --- a/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/verification-follow-up.json +++ b/doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/verification-follow-up.json @@ -14,8 +14,14 @@ "correction": "Require a successful complete process-list read with verifier PID; all command failures propagate.", "regression": "Five actual-source checks pass: original false-positive reproduced; successful absent snapshot; command failures status1/status2/ENOENT/EACCES/SIGTERM rejected; malformed/empty/incomplete snapshot rejected; live captured PID rejected.", "helperSha256": "6072f66a8fedb085f6a321a11c90fbc98b4ee95dfc9b4c3c42010feaf0ae342e", - "testSha256": "3783686a4e3334a8ada07ec157b201c28d07412c7746b73d26a807ba230f9aeb", - "independentOriginalEvidence": "independent-successful-process-snapshot.json" + "testSha256": "4a7661e68843efb97e353eed3aa9c38c024e78d2a2f5ceb8ef3a4c0912ab0471", + "independentOriginalEvidence": "independent-successful-process-snapshot.json", + "beforeSourceFixture": { + "path": "helpers/verify-birth-settlement-before.source.txt", + "sha256": "3eca4c0bd960e87225fee9c74a6f9ef0eb785b3d3766bc8435900aaa266d4d46", + "originCommit": "d05f9b0db71eaee823b72136ae54611b12a72f35", + "scope": "Exact archived faulty source consumed as text by stubbed regression; no historical Git object needed at test execution" + } } ], "limits": [ diff --git a/scripts/native-ingestion/live-process-check.mjs b/scripts/native-ingestion/live-process-check.mjs index fbcef17f4e0..cfb0a90dfb3 100644 --- a/scripts/native-ingestion/live-process-check.mjs +++ b/scripts/native-ingestion/live-process-check.mjs @@ -1,11 +1,10 @@ import assert from 'node:assert/strict'; import { test } from 'node:test'; import { readFile } from 'node:fs/promises'; -import { execFileSync } from 'node:child_process'; const file = 'doc/benchmarks/native-event-ingestion-2026-11-03/live-ce33-914/helpers/verify-birth-settlement.mjs'; const source = await readFile(new URL('../../' + file, import.meta.url), 'utf8'); -const before = execFileSync('git', ['show', 'd05f9b0db71eaee823b72136ae54611b12a72f35:' + file], { encoding: 'utf8' }); +const before = await readFile(new URL('../../' + file.replace('.mjs', '-before.source.txt'), import.meta.url), 'utf8'); const gate = { chain: [{ pid: 101, birthTime: 'fixture-birth', executable: 'fixture-provider' }] }; function check(text, ps) { const start = text.includes('const processList = ') ? text.indexOf('const processList = ') : text.indexOf('const checks=gate.chain.map');