leonida-lua: the dangling-link test builds against the infallible Runtime::new (D3D12-LUA-TESTS-BUILD) #3237
Closed
github-bot
wants to merge 1 commit from
github-bot/gh-3237 into main
AGit
pull from: github-bot/gh-3237
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!3237
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3237"
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?
@LouisRiverstone on GitHub · 2026-12-02 21:53 UTC · original
LouisRiverstone:fix/leonida-lua-tests-build→main· +1 −1 · 1 files · 1 commits · closed without mergingClaim: #2570 (D3D12-LUA-TESTS-BUILD), fixing OreoFR's finding that
mainno longer builds the d3d12 tests.Why
Since
bc20b75ba,mainfailsd3d12 (windows-latest)witherror[E0599]: no method named 'unwrap' found for struct 'Runtime'atd3d12/crates/leonida-lua/src/tests.rs:1089, and so does every pull request that touchesd3d12/. It is a merge race:Runtime::new.057cc94d8, "Runtime::new cannot fail any more") changednewto returnRuntime(runtime.rs:157), because each mod now gets its own Lua state at load time.What changed
The test drops the
.unwrap().newstays infallible, as #3179 intended.Verification (Windows 11, pinned toolchain)
cargo test -p leonida-lua --locked: 46 passed. Without the change, the crate's tests do not compile;main's own run on bc20b75ba/f3865cae8 shows the same E0599.cargo build --workspace --all-targets --locked: builds.Runtime::new(...)call uses?,.unwrap()or.expect((13 calls checked).AI assistance
AI-assisted: written with Claude Code (Claude Opus 5.5). It was reviewed by a separate read-only reviewer agent (Claude Opus 5.5), which confirmed #3179's intent, that the test still checks #3189's dangling-link behaviour under per-mod states, and that no other old-API use is left. It found nothing blocking.
🤖 Generated with Claude Code
@merzleckeier on GitHub · 2026-12-02 21:58 UTC · original · reviewed
Reviewed
efc64a091againstmainatf3865cae8. In an isolated checkout with Rust 1.98.1 on Linux,cargo test -p leonida-lua --locked --offline --no-runreproducedE0599from the D3D12 CI job attests.rs:1089. With just this PR’s one-line change applied, the same command built the test executable successfully. The edit matches the currentRuntime::newreturn type and leaves the test assertions intact. This was a compile-only check.@MoonEyes on GitHub · 2026-12-02 21:59 UTC · original
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).
@merzleckeier on GitHub · 2026-12-02 22:02 UTC · original
Update from the Windows D3D12 job on
efc64a091: the workspace gets past compilation and runs the Lua suite. That suite reports 45 passed and one failure,a_scan_without_a_size_reaches_the_end_of_the_image. This is the separate #3193 case already claimed in #2570. The build fix here changes only the test call toRuntime::new.@LouisRiverstone on GitHub · 2026-12-02 22:07 UTC · original
Second commit: with the build fixed, CI reached
tests::a_scan_without_a_size_reaches_the_end_of_the_image, which failed (tail 1 0), although it passes locally. Its result depended on where the heap put the fake image:base - 100cannot be read whole, somemory::scanfalls back to pages aligned to absolute addresses. That matches the reallua_read(leonida-gpu/src/host.rs), which only fails per page.Vec, so the page straddlingbasewas refused whole. Whenbase % 4096is 1–99, that page holds the marker.memory::scangavefound 0at skews 50 and 99, andfound 1at 0, 100, 200 and 2048.The fake image is now a page-aligned
Box<Image>(#[repr(C, align(4096))], which derefs to[u8]), as real memory regions are.cargo test -p leonida-lua --lockedpasses (46) and clippy is clean. A separate read-only reviewer (Claude Opus 5.5) confirmed that the allocation is sound, that every use of the fake still works, that real reads are page-granular, and that no other test depends on where the base lands.@LouisRiverstone on GitHub · 2026-12-02 22:12 UTC · original
Reverted my second commit. The
a_scan_without_a_size_reaches_the_end_of_the_imageflake is #3193. MoonEyes claimed it before I pushed, and #3244 makes the same page-aligned fake plus a test that pins it. This pull request is back to the one-line build fix (git diff origin/maintouches onlytests.rs:1089).Until #3244 merges, the d3d12 job here may hit that flake about one run in twenty (fiestorra's count in #3193). It is not caused by this change.
f69dd5036dto2a5338d79d@LouisRiverstone on GitHub · 2026-12-02 22:24 UTC · original
Squashed into one commit,
2a5338d79, with no co-author trailer. The net diff is unchanged: the single line attests.rs:1089. As merzleckeier noted, the remaining D3D12-job failure is #3193's flake, which #3244 handles. @MoonEyes this is a test-only, one-line Rust change with nothing on the render path, so I don't think the in-game gate applies.github-bot referenced this pull request2026-12-02 22:52:19 +00:00
@fiestorra on GitHub · 2026-12-02 23:06 UTC · original
VERIFY-3237 — Windows nativo: es el arreglo que
mainnecesita, y lo verifiqué entero2a5338d79—d3d12/crates/leonida-lua/src/tests.rs,+1/−1The change, in full:
Ran at the head
And on
main(ef35d683e) the same command does not even compile:So this one line is the difference between
maincompiling its tests and not, which is why every pull request in this repository is red ond3d12 (windows-latest)at the Build step — mine included, and #3178 merged on top of it earlier tonight (I left the evidence in #2570).Please merge this one first. Nothing else in the queue can be judged by CI until it lands: a red Build on a broken
mainis indistinguishable from a red Build caused by the change being reviewed, and I have spent tonight explaining that to reviewers who had no way to know.What I could not test: the other crates' suites under this change — only
leonida-lua, which is the one the line touches.Written with an AI assistant.
@fiestorra on GitHub · 2026-12-02 23:25 UTC · original
mainis fixed — and this pull request no longer has anything to do.origin/mainis now81efe4566(the merge of #3244), and the line this pull request changes is already there:tests.rshas threeRuntime::newcall sites and none unwraps.a22fa26d6(LEONIDA-LUA-SCAN-END-3193, the fake image starting on a page) carried the.unwrap()removal with it.Checked on
81efe4566:where the same command did not compile an hour ago. So: close this one rather than merge it — the fix is in, and a second branch changing the same line is a conflict waiting to be resolved for nothing.
Thank you for having it ready anyway: I asked for it to go first because every PR in the repository was red at Build, and having the one-line fix written down in a PR with a proper item name (
D3D12-LUA-TESTS-BUILD) is what made it easy to point at.Written with an AI assistant.
@LouisRiverstone on GitHub · 2026-12-03 02:05 UTC · original
Closing: #3244 (
a22fa26d6, merged as81efe4566) carried the same one-line.unwrap()removal, somainbuildsleonida-lua's tests again and this change has nothing left to do. Thanks @fiestorra for checking it on81efe4566(47 passed).Pull request closed