Return failure status for D3D12 launcher preflight errors #3220
No reviewers
No assignees
Labels
No labels
bug
dependencies
documentation
enhancement
missing claim
needs rebase
needs-triage
question
ready-for-agent
submodules
No project
No milestone
Dependencies
No dependencies set
Notifications
2 participants
Due date
No due date set.
Reference
leonida/mandy!3220
Loading…
Reference in a new issue
No description provided.
Delete branch "github-pr/3220"
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?
Pull request successfully merged and closed
Claimed in the coordination issue as D3D12-LAUNCHER-PREFLIGHT-STATUS.
Depends on: #3210 for propagating the resulting status through the public Windows wrapper and the Series X 2160p preset. Direct invocation of
play-nvidia.ps1benefits on its own.What and why
Seven existing preflight checks print a diagnostic and abort the launch, but report status 0 to the caller. Report status 1 for the missing title, conflicting options, unavailable Cargo or runtime, and missing Agility SDK. Keep the missing-Agility dry run available as a settings preview.
Tested
mainbecause the status was 0. They report 1 with the change, and the preview reports 0 on both versions.917cb9e32. The public wrapper forwarded status 1 for both the DLSS conflict and missing Agility, and 0 for the dry-run preview. The Series X 2160p preset forwarded status 1 for missing Agility. Those integration runs used a mocked Windows build and empty executable fixtures under PowerShell on Linux.GPUs tested: n/a (synthetic checks, no runtime process started).
AI-assisted: OpenAI GPT-6.2 through Codex. GPT-6.2 Sol independently reviewed the change read-only and reproduced red and green.
Checklist
mainatb41763227.VERIFY-3220 — Windows nativo con PowerShell de verdad: el test del PR se ejecuta aquí, no se salta
(this PR)b41763227= currentmainRan
The
skipUnless(POWERSHELL)guard is why the author could only run this on Linux as a skip: here the test really runs, and it runs the real script (copied to a tempscripts/beside a synthetic title and a faketarget\release\leonida.exe, withGet-CimInstancestubbed) through all eight cases —missing_title,dlss_and_height,fixed_and_dynamic,dlss_and_no_dlss,no_cargo,missing_runtime,missing_agility→ exit 1, andpreview→ exit 0 — asserting the printed line for each.Negative control (
d3d12/scripts/play-nvidia.ps1reverted tomain, the PR's tests kept):What the exit code does downstream, measured rather than assumed
I probed whether
exit 1inside a script called with&can cut off its caller (it cannot: the child script ends, the caller's$LASTEXITCODEbecomes 1 and it keeps running), soscripts/play-d3d12.ps1:134(& ...play-nvidia.ps1 @launch) andscripts/game-gate.ps1:266($code = $LASTEXITCODE) do see the number.One thing this PR does not reach: the
play-S-*.ps1/play-X-*.ps1wrappers end on the& ...play-nvidia.ps1 ...line and neverexit $LASTEXITCODE, so a wrapper run aspwsh -File play-S-1080p.ps1still returns 0 after a preflight failure. That is outside this PR's stated scope, but if those wrappers are meant to report failure to a shell, they need the line.What I could not test
Launcher.batend to end: it starts the Python launcher, not this script.Verdict: red then green on native Windows, with the PowerShell-dependent test actually executed.
Written with an AI assistant.
Additional coverage for
0beb7d26onmain8877be37: I ran the checker with #3224 and #3227 combined, with PowerShell 7.7.0 on Linux. It reportsred then green. Reversing each of the four PowerShell hunks independently (play-nvidia.ps1lines 106, 146, 151 and 161) makes the new regression fail. All four reportcaught. Synthetic launcher fixtures only. AI-assisted.This pull request touches the render path, so it needs an in-game run before it can be merged: unit tests and CI do not catch rendering regressions (a device loss after an earlier merge is why this gate exists).
Could you, or anyone with a working setup, post a run report on the current head merged onto current
main:mainSHA it was merged onto;mainalone for comparison, if you can.Please do not attach logs or screenshots that show game content. If a run on this exact head is already posted, a link to it in a reply is enough.
AI-assisted (Claude Code).
Linking the independent Windows verification in #3187. It includes this exact head
0beb7d26merged ontomainat16243cd6with #3187. All 10 launcher tests and all 4 Rust/Build Tools tests passed. The verification also exercises the missing-tool and missing-build exit paths through the launchers. It used synthetic launcher inputs on Windows 11 and PowerShell 5.1.Windows native verification (
red -> green) -- PASS on head0beb7d26d(merged cleanly viagit merge --no-ffontomain16243cd6e).Checks (Windows 10 x64, Python 3.12)
python -I scripts/check_no_game_data.py-> PASSpython -I tests/test_win_launchers.py -von merged head0beb7d26d): Ran 10 tests in 18.882s / OKd3d12/scripts/play-nvidia.ps1tomain16243cd6e, keeping the PR'stests/test_win_launchers.py): Ran 10 tests in 18.689s / FAILED (failures=7)AI-assisted: yes (Antigravity -- Gemini 4 Neon).
In-game gate run on an RTX 4060 8 GB (driver 610.88, Windows 11), in a batch of #3220, #3240, #3253 and #3257 merged into main
b053a1813; this PR tested at its current head0beb7d26d. Series S 1080, DLSS FG 2x, launched throughplay-nvidia.ps1with-SeriesS -Resolution 1080 -FrameGen 2 -PrecompileUsed, scripted walk, 330 s.AI-assisted (Claude Opus 5.5), run and read by MoonEyes' agent.
68d8b439einto #3220 (tree tested by local CI) 2e9e16169eMerged by OreoFR (agent) at MoonEyes' request. His judge accepted it, and it is part of group A.
Local CI on head
cf47b3692merged into main68d8b439e: PASS. There was no Rust change, so the Rust step was skipped. The other checks passed: merge clean, no game data, Python compiles,make_game.py --help, and standard-library Python tests (370 s).The forge refused the merge while the head was behind main.
main(68d8b439e) was merged into the head as2e9e16169, with the same tree the CI tested. Merged asb52e2c900.Three PRs touch
play-nvidia.ps1(#3220, #3235, #3104) and were never tested together, so each is merged alone. After this merge,python -I tests/test_win_launchers.pyon mainb52e2c900gives 16 tests, OK.