Repository navigation
Adds distinct exit codes for crashed, hung and failing test runs - #7235
myurasov-nv merged 2 commits into
Conversation
Greptile SummaryThe PR gives crashed, timed-out, startup-hung, and assertion-failing orchestrator runs distinct process exit codes while preserving zero for successful runs.
Confidence Score: 5/5The PR appears safe to merge with no actionable correctness, compatibility, or security issue identified. The new resolver receives the counters in the correct order, follows the precedence documented by the change, and preserves the existing success-versus-failure behavior for callers that treat any nonzero status as failure. Important Files Changed
Reviews (1): Last reviewed commit: "Adds distinct exit codes for crashed, hu..." | Re-trigger Greptile |
There was a problem hiding this comment.
Isaac Lab Review Bot
The change centralizes failure-mode exit-code selection in tools/conftest.py and reports the selected code and label in the existing test summary. The exact nonzero exit-code contract intentionally changes for crashes, timeouts, and startup hangs, while success remains 0 and assertion failures remain 1.
- Design and architecture: The precedence rule (crash, timeout, startup hang, assertion failure) is isolated in one helper and reused for both summary reporting and
pytest.exit, preventing those two paths from diverging. The change remains scoped to the test orchestrator and adds no dependencies or package coupling. - API: Checked the externally observable process-exit contract: all successful runs still return 0, assertion-only failures still return 1, and the newly distinguished failure modes return 20–22. Consumers that only distinguish zero from nonzero remain compatible, while consumers matching exactly on 1 will observe the intentional contract change. No source package or public package API is modified.
- Implementation: The helper call uses the same counter order as its signature, its precedence matches the stated behavior, and the label mapping covers every possible return value. The final resolved value is consistently used in both the logged summary and
pytest.exit. The helper lacks type annotations and detailed argument documentation, but that is a non-blocking consistency tradeoff rather than a demonstrated defect.
No blocking issues. No inline issue met the actionable-evidence threshold; the assessment above records the review feedback.
Automated review; human maintainers own approval decisions.
|
Dear Isaac Lab Review Bot!
On the contract change: it is intended, and it is limited to the 3 modes that previously could not be told apart. The consumers I checked do not match on exactly 1, since |
|
Existing CI failures:
The JUnit report for the failing run (32447613867) holds 314 cases with 37 failures, 0 errors, and no timeouts or crashes. Every failure is a pixel-percentage or SSIM threshold on a golden image. This change cannot affect that: it alters the process exit code and one line of the run summary, nothing in the render path. Worth noting for this PR specifically: those 37 failures are ordinary assertion failures, so they resolve to exit code 1, the value the previous expression also returned.
|
## Description Backports five merged `develop` PRs not already represented on `release/3.0.0` or covered by #7300: | Source PR | Source commit | Backport commit | Scope | | --- | --- | --- | --- | | #7235 | `4fa20fc8a5f` | `8110c816d0a` | Report distinct exit codes for failed, crashed, timed-out, and startup-hung test runs. | | #6597 | `2ae0878a266` | `68b21a60158` | Correct the stale wheel-builder dependency-pin reference. | | #7320 | `7ed3ad45546` | `1a775d46fcf` | Add success-driven ADR guidance and evaluation coverage to the domain-randomization skill. | | #7319 | `2c07bbb43a9` | `4249489a089` | Vectorize clone-plan environment-ID queries. | | #7316 | `a00278f0fde` | `8af682bfcb9` | Extend Core Lift and Reorient episodes and pose-command resampling intervals. | Each merged source commit was cherry-picked with `-x`. All five applied without conflicts and have stable patch IDs identical to their source commits. #7233 is intentionally excluded because its existing backport is #7300. ## Type of change - Bug fix - Performance improvement - Task configuration update - Developer tooling improvement - Documentation update ## Validation - `uv run --frozen --extra test python -m pytest -q source/isaaclab/test/cloner/test_clone_plan_algebra.py` — 85 passed. - Validated the six representative `resolve_exit_code` outcomes, including mixed-failure precedence. - `uv run --no-project python tools/skills/cli.py check` — 21 skills validated. - `uv run --frozen --extra test python -m pytest --noconftest -q source/isaaclab_tasks/test/core/test_lift_env_cfg.py` — 3 passed. - Programmatic Lift/Reorient config assertions confirmed the 4–6 second resampling interval and 12-second episode length. - Ruff, Ruff-format, and RST hooks passed for the #7316 paths. - The original four-PR branch passed `ISAACLAB_CHANGELOG_BASE_REF=release/3.0.0 uv run --frozen isaaclab -f`; #7316's source commit also passed its full formatting and changelog validation. - `git diff --check kelly/kellyg/backport-remaining-develop-prs-3.0.0...HEAD` — passed for the added #7316 commit. - Stable patch IDs match all five merged source commits; #7316 also has exact mode/blob parity on both affected paths. ## Screenshots Not applicable. ## Checklist - [x] I have read and understood the contribution guidelines. - [x] I have run the repository formatting or focused pre-commit checks appropriate to each source PR. - [x] Documentation and skill guidance from the source PRs are included unchanged. - [x] My changes generate no new warnings. - [x] Existing and backported tests cover the changed behavior. - [x] Touched release-managed source packages carry their source changelog fragments. - [x] Source authorship and `-x` provenance are preserved. --------- Co-authored-by: myurasov-nv <[email protected]> Co-authored-by: AntoineRichard <[email protected]> Co-authored-by: ooctipus <[email protected]> Co-authored-by: camevor <[email protected]>
Description
Every failure mode in the individual-test orchestrator exits
1, so a crashed process, a hung test, and a failing assertion cannot be told apart from the exit code. The orchestrator already separates them internally: it countsFailing,Crashed,Startup Hang, andTimeout, and prints each in the result summary. This carries that distinction into the exit code and prints the resolved code with a label.1still means failing assertions. A crashed process is20, a timeout21, and a startup hang22. When a run hits more than one, the code reports the outcome that proved the least, so a crash outranks a timeout, which outranks a startup hang.0is unchanged, and callers that only check for a non-zero code are unaffected.Process completed with exit code 120,21, and1, each printed asExit Code: N (label)in the summaryReproduction
Run a suite through the orchestrator and read the exit code:
Make one file reach its hard timeout, by lowering the timeout for that file or running a test that sleeps past it.
Observed before this change: the summary reports
Timeout: 1while the run reportsexit=1, the same code a failing assertion produces.Repeat with this change.
Observed: the summary reports
Exit Code: 21 (timeout)and the run reportsexit=21, while a run whose only failures are assertions still reportsexit=1.Type of change
Screenshots
Not applicable; the change has no rendered output.
Checklist
pre-commitchecks with./isaaclab.sh --format: not run; no dev setup on this machine. The diff was checked by hand for line length and whitespace, andpython3 -m py_compile tools/conftest.pypassespytest_sessionstart, andtools/conftest.pytakes over any pytest session that loads it, so a test in the same directory cannot drive this path in-process.resolve_exit_codewas instead checked over all 16 combinations of the 4 counters, confirming that each mode maps to its own code and that zero versus non-zero matches the previous expression exactlysource/<pkg>/changelog.d/for every touched package (do not editCHANGELOG.rstor bumpextension.toml— CI handles that): not applicable; no package undersource/is touchedCONTRIBUTORS.mdor my name already exists there