Report Cargo test targets that exit early in red-green #3307
Open
github-bot
wants to merge 2 commits from
github-bot/gh-3307 into main
AGit
pull from: github-bot/gh-3307
merge into: github:main
github:main
github:perf/darner-title-priority-ceiling
github:gh-readonly-queue/main/pr-3311-b5c45b663dbc5a9c3532bb3f307e5f81b32faefa
github:gh-readonly-queue/main/pr-3088-af22e7847ff5808f72d1a1881c24be2fafd20b54
github:gh-readonly-queue/main/pr-3123-7f3fa026a94c6646e89244f28e1ce22290361867
github:gh-readonly-queue/main/pr-3354-637baa0b77ba47222e7280b17c1a59c6a1781d57
github:gh-readonly-queue/main/pr-3365-d7a0e0196a43834813014b4bd3aa5502a8263b14
github:gh-readonly-queue/main/pr-3361-5dfe8bbd05ed12fb2f2e1718d9af77a7c5f46fd8
github:gh-readonly-queue/main/pr-3366-8da9148204e9d12c585efa9ac2b7cc1ab08c7682
github:fix/runtime-test-conservative-fixtures
github:ci/shard-semantic-linux
github:docs/fg-limit-fps-switch
github:fix/runtime-test-fixture-paths
github:fix/runtime-test-fixture-readers
github:fix/read-file-hard-link
github:fix/book-slot-heap-never-read
github:fix/depth-resolve-spv-path
github:fix/indirect-unused-batched
github:gh-pr/3358/base
github:fix/xmem-refusal-diagnostics
github:gh-pr/3357/base
github:ci/shorten-ci-time
github:fix/alias-later-queued-submissions
github:claude/gallant-sagan-aamatr
github:gh-pr/3342/base
github:gh-pr/3341/base
github:d3d12/agility-sdk-621
github:gh-pr/3293/base
github:gh-pr/3319/base
github:gh-pr/3318/base
github:gh-pr/3315/base
github:gh-pr/3313/base
github:gh-pr/3314/base
github:claude/fervent-curie-m19lnr
github:gh-pr/3216/base
github:gh-pr/3272/base
github:gh-pr/3276/base
github:gh-pr/3279/base
github:gh-pr/3257/base
github:gh-pr/3258/base
github:gh-pr/3271/base
github:codex/skip-no-hit-ray-passes
github:gh-pr/3230/base
github:gh-pr/3266/base
github:gh-pr/3247/base
github:gh-pr/3246/base
github:gh-pr/3244/base
github:claude/sharp-sagan-1jqnp3
github:t3/preserve-fsr-sdk-restart-path
github:t3/propagate-host-failure-hresult
github:t3/launcher-custom-parameters
github:t3/series-x-2160-startup
github:codex/d3d12-uncapped-simulation
github:ci/less-to-run
github:perf/native-compute-shader-forms
github:claude/blissful-franklin-ukp7ag
github:codex/full-precompile-default
github:gh-pr/3166/base
github:gh-pr/3148/base
github:gh-pr/3138/base
github:gh-pr/3106/base
github:gh-pr/3057/base
github:gh-pr/2756/base
github:gh-pr/2812/base
github:gh-pr/3032/base
github:gh-pr/2992/base
github:notes/card-time-and-plant-flicker
github:gh-pr/2986/base
github:gh-pr/3000/base
github:gh-pr/2966/base
github:gh-pr/2924/base
github:gh-pr/726/base
github:gh-pr/2761/base
github:gh-pr/2663/base
github:gh-pr/2861/base
github:gh-pr/2862/base
github:gh-pr/2820/base
github:gh-pr/2811/base
github:gh-pr/2803/base
github:rt-call-trace
github:gh-pr/2802/base
github:gh-pr/2766/base
github:perf/ahead-split
github:gh-pr/2589/base
github:gh-pr/2699/base
github:gh-pr/2696/base
github:docs/readme-runtime-proposal
github:gh-pr/1346/base
github:codex/coord-claim-check-20261124-7e48
No reviewers
Labels
Clear labels
accessibility
Barrier affecting people with disabilities
area: ci
.github/ workflows and settings
area: d3d12
The D3D12 runtime in d3d12/ (Rust: leonida.exe and its crates)
area: docs
Documentation
area: launcher
The launcher (launcher/)
area: runtime (legacy)
The earlier Vulkan runtime in runtime/
area: shader translator
The shader translator (leonida-shader, tools/rdna2spirv) and its tests
area: tools
tools/ and scripts/
area: viewer
The map viewer (viewer/)
bug
Something isn't working
dependencies
Pull requests that update a dependency file
documentation
Improvements or additions to documentation
duplicate
This issue or pull request already exists
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
invalid
This doesn't seem right
missing claim
Needs a claim in #14
needs in-game run
Changes the code a frame runs through: needs the 300 s in-game gate (docs/game_gate.md)
needs rebase
Conflicts with the base branch: rebase it on main
needs-triage
Needs maintainer evaluation before the next triage state
question
Further information is requested
ready-for-agent
Fully specified and ready for an AFK agent
submodules
Pull requests that update submodules code
wontfix
This will not be worked on
No labels
accessibility
area: ci
area: d3d12
area: docs
area: launcher
area: runtime (legacy)
area: shader translator
area: tools
area: viewer
bug
dependencies
documentation
duplicate
enhancement
good first issue
help wanted
invalid
missing claim
needs in-game run
needs rebase
needs-triage
question
ready-for-agent
submodules
wontfix
Milestone
Clear milestone
No items
No milestone
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".
No due date set.
Dependencies
No dependencies set
Reference
github/ubiquitarianism--leonida!3307
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3307"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@merzleckeier on GitHub · 2026-12-03 08:00 UTC · original
merzleckeier:codex/red-green-cargo-target-exit→main· +106 −16 · 3 files · 3 commits · openClaimed as
TEST-RED-GREEN-CARGO-TARGET-EXIT. Coordination commentDepends on: none.
What and why
With
cargo test --no-fail-fast, Cargo can finish one test target and then report that another target exited early. The checker used the successful target’s parsed results and could returnred then greenwith exit 0 even though the second executable failed.Record Cargo’s rerun command when a failed target exits before reporting a test summary. An incomplete red side gets
red test run failed. An incomplete green side getsgreen fails. An interrupted target during a mutation is reported astest run failed. Ordinary assertion failures stay in the per-test results.Tested
mainand passed with this change.mainand exit 1 with the fix. A separate mutation fixture now reportstest run failedinstead ofnot caught.python3 -I tests/test_red_green.py -q: 42 tests, one platform skip. Scratch merge with #3304: 44 tests, one platform skip.git diff --checkandpython3 -I scripts/check_no_game_data.py docs/testing.md scripts/red_green.py tests/test_red_green.pypassed.GPUs tested: CPU-only checks on Linux. No game files were used.
AI-assisted with OpenAI Codex (GPT-6). A separate read-only Codex GPT reviewer checked the final diff and reproduced the Cargo cases independently. The reviewer’s exact runtime variant was unavailable.
@lixonik on GitHub · 2026-12-03 08:13 UTC · original
Windows native verification (
red -> green) -- PASS on head11da4b655(merged cleanly viagit merge --no-ffontomaind9b618f10).Checks (Windows 10 x64, Python 3.12)
python -I scripts/check_no_game_data.py-> PASSpython -I tests/test_red_green.py -v-> Ran 42 tests in 77.147s / OKscripts/red_green.pytomaind9b618f10, keeping the PR'stests/test_red_green.py): Ran 42 tests in 77.838s / FAILED (failures=3) (exit1)AI-assisted: yes (Antigravity -- Gemini 4 Neon).
@fiestorra on GitHub · 2026-12-03 08:39 UTC · original
Las dos nuevas, corridas
En
#3306el fallo es el de siempre (views_are_made_beside…, la iGPU de esta máquina), y720contra los715demain— cinco tests más, medidos en el diff.Y el cambio es de los que no se pueden probar sin el juego: envolver los
GetProcAddressdel port 2 y marcar las importaciones «al lado» — o sea, hacer que una llamada que no existe en la DLL del juego se vea como tal y no como un salto a la nada. Lo que el test cubre es el envoltorio; lo que no cubre es una DLL real sin ese símbolo.En
#3307la proporción vuelve a ser la buena: 106 líneas, de las cuales la mayoría son test (+10 subtests sobre los 8 que tenía), en una herramienta de medición. Y es la tercera de la noche sobrered_green(con#3304y el propio fichero), que empieza a ser el instrumento más revisado del repositorio — y con razón: es el que dice si algo está rojo.Lo que no verifiqué en ninguna: el caso que las motiva — una DLL del juego sin el símbolo (
#3306) y una suite mutada que sale antes de tiempo (#3307). Los dos necesitan un binario concreto, y los dos están simulados en los tests.@merzleckeier on GitHub · 2026-12-03 09:18 UTC · original
Found a remaining false green on
11da4b65with real Cargo 1.97.1 and a synthetic Rust crate. The green target starts a child libtest that prints a successful summary, then the enclosing target exits before its own summary. Cargo exits 101 and reports a target failure.red_green.pystill exits 0 withred then greenand an emptygreen.test_run_errorslist. I reproduced this with enclosing test exit statuses 2 and 101.The child summary sets
target_finishedbefore Cargo reports the enclosing failure. Using Cargo’s process-exit diagnostic is enough for the status-2 case here. Cargo omits that detail for the status-101 case. A local control that tracks the nested libtest starts and summaries reportsgreen failsfor both. Its existing checker suite ran 42 tests with 41 passing and one platform skip. The control was exercised locally. AI-assisted with OpenAI Codex.@icdmkg2 on GitHub · 2026-12-03 11:47 UTC · original
Verified natively on Windows 11 (Python 3.12, no game files): \python -I scripts/red_green.py 3307 --no-cargo\ against \origin/main\ (\053a1813, head \
11da4b655) — *\erdict: red then green* (1 red→green: \Mutation.test_a_mutation_that_interrupts_another_test_target_reports_it, 1 green-only \ok: \Sides.test_a_cargo_target_that_exits_early_cancels_the_sides_verdict, 40 pass on both). AI-assisted: Gemini 4 Neon (Antigravity).@aegish-zagi on GitHub · 2026-12-03 14:39 UTC · original
VERIFY-3307 — PASS
11da4b65| merge with current main128579e9e: clean (ort merge, no conflicts)python3 -I tests/test_red_green.pyscripts/red_green.pyscripts/red_green.pyonly (plus its tests anddocs/testing.md). The parser now tracks a per-targeterror: test failed, to rerun pass …line and keeps it only when that target never prints atest result:summary, clearing all such errors when Cargo exits 0 — so a target that exits early is reported instead of silently dropped, without misreporting ordinary failed tests. No game data, stdlib only.AI-assisted: yes (Muse Wonder, Muse by Meta)
@merzleckeier on GitHub · 2026-12-03 14:45 UTC · original
I checked #3224
22e03b5e, #33044a848b05, and #330711da4b65together on128579e9. Merging the three heads in forward and reverse order was conflict-free and produced the identical treea0046cad. The combinedtests/test_red_green.pyrun under Python 3.14.10 had 44 passes and one Windows-only skip.One additional mixed run used real Cargo 1.98.1 with synthetic crates plus Python unittest fixtures. The report retained the passing Rust and Python tests, marked the Python parent method failed after a subtest failure, recorded the other Python file as unable to import, and reported the separate Cargo target that exited early. This checks how the three changes compose. AI-assisted (Codex).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.