Skip to content

fix: propagate summary write failures - #204

Merged
HaoZeke merged 3 commits into
developfrom
fix/summary-write-status
Nov 26, 2026
Merged

HaoZeke merged 3 commits into
developfrom
fix/summary-write-status

Conversation

@HaoZeke

@HaoZeke HaoZeke commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

fix: propagate summary write failures

A run treated summary destination failures as warnings and retained exit
status 0, so callers could accept a successful run after its summary
write failed. Summary files now use the shared atomic writer, and a
summary failure makes the command return status 1.

The CLI reproducer is run with the usual --site and --target
values after creating summary.json as a directory in the run
directory; the command now reports the destination error through its
exit status.

The new test a_summary_destination_directory_fails_the_run in
tests/summary.rs checks that a directory at the JSON summary
destination makes an otherwise successful run fail.

Restack onto d4f8e8b:
The shared atomic writer for summary files is already on main
(0baa6e8, changelog.d/+summary-writer-shared-atomic.bugfix.md), so that
part of the patch was not repeated. The exit status change remains.
The reference pages that quoted the old warning were updated with the
example script. A signal still outranks a summary write error.

A run treated summary destination failures as warnings and retained exit
status 0, so callers could accept a successful run after its summary
write failed. Summary files now use the shared atomic writer, and a
summary failure makes the command return status 1.

The CLI reproducer is `run` with the usual `--site` and `--target`
values after creating `summary.json` as a directory in the run
directory; the command now reports the destination error through its
exit status.

The new test `a_summary_destination_directory_fails_the_run` in
`tests/summary.rs` checks that a directory at the JSON summary
destination makes an otherwise successful run fail.
@HaoZeke
HaoZeke changed the base branch from fix/refuse-output-symlinks to main November 19, 2026 02:39
@HaoZeke
HaoZeke force-pushed the fix/summary-write-status branch from edb76d8 to 6c8759e Compare November 20, 2026 23:53
@HaoZeke
HaoZeke changed the base branch from main to develop November 21, 2026 05:30
A summary file of the wrong kind, a bundle manifest, and other refused
destinations still expected a warning and exit 0. They now expect
status 1 and the summary write error, and the file is left unchanged.
@HaoZeke
HaoZeke merged commit 8bad709 into develop Nov 26, 2026
8 checks passed
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.

1 participant