Repository navigation
test(builder): the NUP cache checks no longer depend on the clone's work folder - #2291
Conversation
…ork folder tests/test_make_game_cache.py runs make_game.main() up to the lift with every process launch refused. make_game copies the play profile (hot list, link order, PGO profile, chunk boundaries) from <checkout>/work, and on Linux probes the PGO profile with clang: in a clone that holds the profile there, as CONTRIBUTING.md has developers put it, three of the eleven checks failed on that launch, and passed again with the profile moved aside. The checks now run make_game as from an empty checkout inside their temporary folder (make_game.ROOT patched, as test_make_game_ngx.py and test_ship_state_list.py do), and with a fixed lift key: the key hashes nx2/ relative to the checkout, which os.path.relpath refuses across drives on Windows, and it is not what these checks are about. Assisted-by: Claude Opus 5.5 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Rebased onto main |
39fab55 to
8fbeac9
Compare
Joey-Magnus
left a comment
There was a problem hiding this comment.
Looks good. Pointing make_game.ROOT at an empty checkout inside the test's temp folder is the same isolation test_make_game_ngx.py and others already use, and it removes the dependency on whatever is in the clone's work/. Since lift_key hashes HERE (the real nx2/) relative to ROOT, faking ROOT alone would break relpath on Windows across drives. Stubbing lift_key is the right call, and tests/test_lift_cache.py still covers the key itself. I ran tests/test_make_game_cache.py at the PR's head on Linux, and it passes. CI shows it passing on both Windows parts and both Ubuntu parts.
About the two red jobs, so nobody holds the PR for them:
- Python source checks (windows-2022, part 1/2) failed in
tests/test_native_astc_texture_count.py(scanfdeprecated under-Werrorwith the MSVC CRT). This PR doesn't touch that test, and #2397 (d2073609) has since fixed it on main. A merge or rebase onto current main, or just a rerun after merge, will clear it. - appimage failed on
TimeoutError: [Errno 110] Connection timed outwhile fetching dependencies. That's network flakiness, so a rerun should do.
No changes needed from my side.
|
Thanks for the Linux run and CI check. The isolated-fixture fix is now merged as |
tests/test_make_game_cache.pyfails in every clone that holds the play profile in itswork/folder, which is whereCONTRIBUTING.md tells developers to put it: three of its eleven checks stop on a clang process they did not expect.
Part of #2334.
What changed
tests/test_make_game_cache.pyrunsmake_game.main()up to the lift with every process launch refused. On its waymake_game copies the play profile (hot list, link order, PGO profile,
image/chunks.txt) from<checkout>/work, andon Linux
profile_readable()starts clang to see whether it can read the PGO profile: that launch failedtest_changed_source_replaces_romfs_and_exefs_together,test_same_source_reuses_the_cacheandtest_update_replaces_clearable_scratch_exefs(Unexpected process launch).make_game.ROOTpatched,as
test_make_game_ngx.py,test_ship_state_list.pyandtest_pipeline_states.pydo), so nothing of thedeveloper's
work/is read or copied.lift_keya fixed result. It hashesnx2/with paths relative to the checkout, and with the checkoutmoved into the temporary folder
os.path.relpathwould refuse paths on another drive (Windows CI: the checkout onD:, the temporary folder onC:). The lift key is not what these checks are about;tests/test_lift_cache.pycovers it.
Tests only; the builder is unchanged.
How it was tested
Linux (Arch, Python 3.12.16 and 3.14.8):
work/of the clonepython -I -B tests/run_all.pyon main 49f75dc with this change, the play profile in the clone'swork/(2026-11-11,load 66 to 114): 360 passed, 4 failed, 10 skipped;
tests/test_make_game_cache.pypasses. Two of the failures are thismachine's and fail on main as well, each with a pull request of its own:
tests/test_wayland_libdecor_hint.py(Clang23) and
tests/test_updater_asset_digest.py(only a .NET 10 SDK here). The other two failed under that load and passwhen run alone afterwards:
nx2/test_depth_sample_types.py(its compiler was killed by SIGKILL) andtests/test_display_pointer.py(its reader thread had made no read yet when the check ended; passed 3 of 3 alone).Not tested
Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com