Skip to content

Print only the current quickstart failure summary - #219

Open
tpn wants to merge 1 commit into
mainfrom
codex/quickstart-current-summary-218
Open

tpn wants to merge 1 commit into
mainfrom
codex/quickstart-current-summary-218

Conversation

@tpn

@tpn tpn commented Nov 21, 2026

Copy link
Copy Markdown
Collaborator

Fixes #218.

Running the quickstart twice with the same output directory could make the second invocation print the first run's successful JSON before exiting with an error. The CLI now prints a failure summary only when the current invocation has written one. An existing output directory still produces an error on stderr and exit code 1. A component failure in a new directory still prints its persisted failure summary.

All 11 quickstart tests pass, including both failure cases. Two concurrent xRay CPU quickstarts targeting one directory produced one success and one failure with empty stdout. The changed-file hooks, mypy and lock checks passed.

@tpn
tpn requested a review from melo-gonzo as a code owner November 21, 2026 17:46
@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one): 1

  • ai-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

@tpn
tpn force-pushed the codex/quickstart-current-summary-218 branch from c562cd6 to 5b1111d Compare November 21, 2026 18:54
A second invocation can fail before it creates its output directory.
Reading summary.json from that directory can report a previous success.
Print a failure summary when the current component run records it, while
preserving the original exception for Python callers.

Signed-off-by: Trent Nelson <trentn@nvidia.com>
@tpn
tpn force-pushed the codex/quickstart-current-summary-218 branch from 5b1111d to c6d5af2 Compare November 21, 2026 19:56

@melo-gonzo melo-gonzo left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving. The existing-directory check at examples/run_quickstarts.py:638-641 runs before this invocation writes anything, so stdout now stays empty in the case from #218. mkdir without exist_ok also turns a race between two runs into the same error. A component failure prints the summary from on_failure right after _write_json saves it. Both use the same json.dumps settings, which is why the new test can compare stdout with the file byte for byte.

This branch has not been deployed

No deployments
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.

Failed run_quickstarts.py re-run outputs previous run's successful summary.json to stdout

2 participants