test_bvh_shaders_stage: give the fake FSPX translation its fspx_code_sha256 #211

Open
github-bot wants to merge 1 commit from github-bot/gh-211 into main AGit
Owner

@⁠Andretuta on GitHub · 2026-11-24 02:45 UTC · original
ubiquitarianism:old-pr/9946 → main · +1 −1 · 1 files · 1 commits · draft

Carried over from old PR 9946 by icecreammule277-dot in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9946, exactly that PR's last commit. All carried-over PRs are listed in #17.
Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it.
icecreammule277-dot: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one.


Original description (mentions and #N references are disabled; the numbers refer to the old repository):

Claimed in the coordination issue as: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116875154 (test fix, no ID assigned)

Depends on: none.

What and why

cc495ee43 ("Rebuild an FSPX cache without a compute lookup key") made make_game.fspx_cache_complete require at least one stage == "cs" entry carrying a 64-hex fspx_code_sha256, and updated the fake translator in tests/test_fspx_shaders_stage.py to match. tests/test_bvh_shaders_stage.py models the FSPX index separately, in its own fake rdna2spirv.py, and still wrote {"Upscale": {"stage": "cs"}} with no key. The FSPX step therefore never counts as cached, and the second stage() call reruns fspx_unpack.py and rdna2spirv.py, so test_the_builder_runs_after_fspx_and_alone_when_only_its_dll_changes fails on main ("Lists differ: ['fspx_unpack.py', 'rdna2spirv.py'] != []").

The fake now writes {"stage": "cs", "fspx_code_sha256": "e" * 64} for the FSPX program, as the other file's fake does. Test only; no production change. The builder (BVH) entry is untouched.

Tested

Windows 11 (10.0.26300), CPython 3.15.2, no GPU or game files, on main d083a2cc3:

test main this branch
tests/test_bvh_shaders_stage.py FAIL (1 failure of 13) OK (13 tests)
tests/test_fspx_shaders_stage.py OK OK
tests/test_shader_stage_resume.py OK OK

AI-assisted: yes (Claude Code, Claude Sonnet 5.5).

Checklist

  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (n/a: test only)
**@⁠Andretuta** on GitHub · 2026-11-24 02:45 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/211) `ubiquitarianism:old-pr/9946` → `main` · +1 −1 · 1 files · 1 commits · draft > Carried over from **old PR 9946** by `icecreammule277-dot` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9946`, exactly that PR's last commit. All carried-over PRs are listed in #17. > Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it. > `icecreammule277-dot`: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one. --- Original description (mentions and `#N` references are disabled; the numbers refer to the old repository): Claimed in the coordination issue as: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116875154 (test fix, no ID assigned) Depends on: none. ### What and why `cc495ee43` ("Rebuild an FSPX cache without a compute lookup key") made `make_game.fspx_cache_complete` require at least one `stage == "cs"` entry carrying a 64-hex `fspx_code_sha256`, and updated the fake translator in `tests/test_fspx_shaders_stage.py` to match. `tests/test_bvh_shaders_stage.py` models the FSPX index separately, in its own fake `rdna2spirv.py`, and still wrote `{"Upscale": {"stage": "cs"}}` with no key. The FSPX step therefore never counts as cached, and the second `stage()` call reruns `fspx_unpack.py` and `rdna2spirv.py`, so `test_the_builder_runs_after_fspx_and_alone_when_only_its_dll_changes` fails on `main` ("Lists differ: ['fspx_unpack.py', 'rdna2spirv.py'] != []"). The fake now writes `{"stage": "cs", "fspx_code_sha256": "e" * 64}` for the FSPX program, as the other file's fake does. Test only; no production change. The builder (BVH) entry is untouched. ### Tested Windows 11 (10.0.26300), CPython 3.15.2, no GPU or game files, on `main` d083a2cc3: | test | `main` | this branch | |---|---|---| | `tests/test_bvh_shaders_stage.py` | FAIL (1 failure of 13) | OK (13 tests) | | `tests/test_fspx_shaders_stage.py` | OK | OK | | `tests/test_shader_stage_resume.py` | OK | OK | AI-assisted: yes (Claude Code, Claude Sonnet 5.5). ### Checklist - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [x] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. (n/a: test only)
cc495ee43 made fspx_cache_complete require a compute entry with a
fspx_code_sha256 and updated test_fspx_shaders_stage.py's fake translator,
but this file models the FSPX index separately and still wrote
{"stage": "cs"} alone. The FSPX step then never counted as cached, so the
second stage() call reran fspx_unpack.py and rdna2spirv.py and
test_the_builder_runs_after_fspx_and_alone_when_only_its_dll_changes failed.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 08:48:55 +00:00
This pull request has changes conflicting with the target branch.
  • tests/test_bvh_shaders_stage.py
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/211/head:github-bot/gh-211'
git switch 'github-bot/gh-211'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-211'
git switch 'github-bot/gh-211'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-211'
git switch 'github-bot/gh-211'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-211'
git switch 'main'
git merge --squash 'github-bot/gh-211'
git switch 'main'
git merge --ff-only 'github-bot/gh-211'
git switch 'main'
git merge 'github-bot/gh-211'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.