Skip to content

fix(ci): tolerate Pi diagnostic file locks - #545

Merged
stamp-build[bot] merged 2 commits into
mainfrom
agent/otter/pi-rpc-diagnostic-writes
Oct 30, 2026
Merged

stamp-build[bot] merged 2 commits into
mainfrom
agent/otter/pi-rpc-diagnostic-writes

Conversation

@stamp-build

@stamp-build stamp-build Bot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Otter from open-agent-runtime opened this pull request through Stamp
View in Stamp →


A Windows Pi RPC vendor run reported all 85 tests passed but exited 1 because the diagnostic reporter threw EPERM while replacing active-tests.json (retained run). The reporter now retries a busy rename three times with 20 ms between attempts. Exhaustion records diagnostic_write_failed with the operation, error code and attempt count. Directory, log, snapshot and fallback-output errors are contained so diagnostic I/O does not become an unhandled test-run error; subsequent events can recover.

The regressions cover temporary and persistent replacement failures, other diagnostic writes and a closed output pipe. On Windows, a real file handle prevents replacement while a nested Vitest run executes: both a passing case and an intentional assertion failure must keep their original exit codes and recorded results.

Validation: CI=1 pnpm run check passed (2,516 tests and 18 mock behavior checks). All 85 native Pi RPC vendor tests passed with diagnostics enabled after removing this managed runner's inherited PI_PACKAGE_DIR override. The initial run is retained separately: 14 cases read the host's 1.0.56 package metadata instead of bundled Pi 1.4.0. Windows file-lock regressions await CI.

Task #97. The five investigation runs did not reproduce the earlier 25-minute cancellation; this fixes the observed reporter failure, without attributing the file lock to a particular process.

The first Windows CI run confirmed the real file lock and successful child test, but the outer regression incorrectly expected exitCode 0. The existing runExecutable contract returns ok=true and exitCode=null on success. The revision checks ok, the documented exitCode, and absence of failure diagnostics; it retains the file-lock, case outcome, and EPERM assertions. Full local check passed again. Windows validation of this revision is pending.

@stamp-build
stamp-build Bot merged commit 774753f into main Oct 30, 2026
63 of 71 checks passed
@stamp-build
stamp-build Bot deleted the agent/otter/pi-rpc-diagnostic-writes branch October 30, 2026 10:33
@stamp-build stamp-build Bot mentioned this pull request Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants