w64_graphics: a vk_harness timeout fails that fixture; the rest still run (#9764) #48

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

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

Carried over from old PR 9770 by Joaco9020 in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9770, 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.
Joaco9020: 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):

Fixes #9764. Claim: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7115571350

Depends on: none.

What and why

runtime/test/shaders/w64_graphics.py runs vk_harness through subprocess.run(..., timeout=120) in four places (_draw_heap, _wave_size, live_width, draw). A draw that hangs past the timeout raised subprocess.TimeoutExpired out of main(), so a multi-fixture run ended in a traceback and never reported the fixtures after it (#9764).

main() now catches TimeoutExpired around each fixture's check(), prints vk_harness timed out after 120 s on that fixture's line (counted as a failure), runs the remaining fixtures, and still exits 1. Five lines; the four call sites are unchanged.

Tested

Windows 11, Python 3.12.10, on main 5d74c2723:

  • python -I tests/test_w64_graphics_args.py: 4 tests OK, including the new test_a_timeout_fails_that_fixture_and_the_rest_still_run: a fake vk_harness times out on its first call and reports the device as unsupported afterwards; ps_w64_a_skip gets the timeout line, gs_w64_a_ring is still checked (SKIP), and main() returns 1.
  • Negative control: the new test against the old w64_graphics.py errors with the TimeoutExpired traceback from the issue.
  • python -m pytest tests/test_w64_graphics_probe.py tests/test_w64_graphics_reference.py: 5 passed.
  • Real run on an NVIDIA GeForce RTX 3070 (driver 621.01, VS 2022 build): w64_graphics.py <fixtures> runtime/build/RelWithDebInfo: 17 ok, 12 tier C SKIP, exit 0, the same as before the change.

No game files.

AI-assisted: yes (Claude).

🤖 Generated with Claude Code

**@⁠Andretuta** on GitHub · 2026-11-24 02:07 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/48) `ubiquitarianism:old-pr/9770` → `main` · +36 −1 · 2 files · 1 commits · draft > Carried over from **old PR 9770** by `Joaco9020` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9770`, 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. > `Joaco9020`: 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): Fixes `#9764`. Claim: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7115571350 Depends on: none. ### What and why `runtime/test/shaders/w64_graphics.py` runs `vk_harness` through `subprocess.run(..., timeout=120)` in four places (`_draw_heap`, `_wave_size`, `live_width`, `draw`). A draw that hangs past the timeout raised `subprocess.TimeoutExpired` out of `main()`, so a multi-fixture run ended in a traceback and never reported the fixtures after it (`#9764`). `main()` now catches `TimeoutExpired` around each fixture's `check()`, prints `vk_harness timed out after 120 s` on that fixture's line (counted as a failure), runs the remaining fixtures, and still exits 1. Five lines; the four call sites are unchanged. ### Tested Windows 11, Python 3.12.10, on `main` `5d74c2723`: - `python -I tests/test_w64_graphics_args.py`: 4 tests OK, including the new `test_a_timeout_fails_that_fixture_and_the_rest_still_run`: a fake `vk_harness` times out on its first call and reports the device as unsupported afterwards; `ps_w64_a_skip` gets the timeout line, `gs_w64_a_ring` is still checked (SKIP), and `main()` returns 1. - **Negative control**: the new test against the old `w64_graphics.py` errors with the `TimeoutExpired` traceback from the issue. - `python -m pytest tests/test_w64_graphics_probe.py tests/test_w64_graphics_reference.py`: 5 passed. - Real run on an **NVIDIA GeForce RTX 3070** (driver 621.01, VS 2022 build): `w64_graphics.py <fixtures> runtime/build/RelWithDebInfo`: 17 ok, 12 tier C SKIP, exit 0, the same as before the change. No game files. AI-assisted: yes (Claude). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
A draw that hung past subprocess.run's 120 s timeout raised TimeoutExpired out
of main(), so a multi-fixture run ended in a traceback and never reported the
fixtures after it. main() now reports "vk_harness timed out after 120 s" for
that fixture, goes on, and still exits 1. The test drives main() and check()
with a vk_harness that times out on its first call.

Fixes #9764

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 08:42:17 +00:00
This pull request has changes conflicting with the target branch.
  • tests/test_w64_graphics_args.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/48/head:github-bot/gh-48'
git switch 'github-bot/gh-48'

Merge

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