title_window, xgameruntime_offline: skip what needs a desktop when there is no interactive window station #2139

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

@⁠qhukz13 on GitHub · 2026-11-25 22:46 UTC · original
qhukz13:cont/tests-session0-skip → main · +21 −7 · 3 files · 1 commits · open

Item: TEST-SESSION0-DESKTOP-SKIP

Problem

Run over OpenSSH or as a service, a process lives in session 0, whose window station is not interactive. Two runtime tests fail there for reasons that are not runtime bugs:

  • title_window: no window is ever visible, so find_title_window has nothing to pick and the test stops at title_window_test.cpp:85 (found == windows.title).
  • xgameruntime_offline and xgameruntime_offline_hdr: PowerSetRequest(PowerRequestDisplayRequired) answers ERROR_NOT_SUPPORTED (50) in session 0, so XDisplayAcquireTimeoutDeferral acquires a display power request handle and concurrent display deferrals have distinct handles fail. The system and away-mode requests do work there (measured with a small PowerShell probe of the same calls over SSH).

From a desktop session all three pass. #1217 already notes the SSH difference for xgameruntime_offline.

Change

  • title_window_test: returns 77 (SKIP, with a line saying why) when has_interactive_window_station() is false; SKIP_RETURN_CODE 77 on the test.
  • xgameruntime_offline_test: when the first acquire answers HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED) and there is no interactive window station, it checks that no handle was left and prints a SKIP line for the two handle checks; everywhere else they are checked as before. The rest of the test is unchanged.
  • Both use runtime/test/window_station.h's has_interactive_window_station() (the WSF_VISIBLE flag), as the DXGI and present tests already do. No runtime change.

Testing

Windows 10 Pro 19045, GTX 1050 Ti, NVIDIA 582.66, MSVC RelWithDebInfo, base 5fab93967, 3 runs each way:

  • Over OpenSSH (session 0): title_window Skipped, xgameruntime_offline and xgameruntime_offline_hdr pass (on main all three fail there).
  • In an RDP desktop session on the same machine: all three pass with every check run.
  • python -I scripts/check_no_game_data.py on the changed files: clean.

AI-assisted (Claude Code, Opus 5.5).

🤖 Generated with Claude Code

**@⁠qhukz13** on GitHub · 2026-11-25 22:46 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/2139) `qhukz13:cont/tests-session0-skip` → `main` · +21 −7 · 3 files · 1 commits · open Item: `TEST-SESSION0-DESKTOP-SKIP` ### Problem Run over OpenSSH or as a service, a process lives in session 0, whose window station is not interactive. Two runtime tests fail there for reasons that are not runtime bugs: - `title_window`: no window is ever visible, so `find_title_window` has nothing to pick and the test stops at `title_window_test.cpp:85` (`found == windows.title`). - `xgameruntime_offline` and `xgameruntime_offline_hdr`: `PowerSetRequest(PowerRequestDisplayRequired)` answers `ERROR_NOT_SUPPORTED` (50) in session 0, so `XDisplayAcquireTimeoutDeferral acquires a display power request handle` and `concurrent display deferrals have distinct handles` fail. The system and away-mode requests do work there (measured with a small PowerShell probe of the same calls over SSH). From a desktop session all three pass. #1217 already notes the SSH difference for `xgameruntime_offline`. ### Change - `title_window_test`: returns 77 (SKIP, with a line saying why) when `has_interactive_window_station()` is false; `SKIP_RETURN_CODE 77` on the test. - `xgameruntime_offline_test`: when the first acquire answers `HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED)` **and** there is no interactive window station, it checks that no handle was left and prints a SKIP line for the two handle checks; everywhere else they are checked as before. The rest of the test is unchanged. - Both use `runtime/test/window_station.h`'s `has_interactive_window_station()` (the `WSF_VISIBLE` flag), as the DXGI and present tests already do. No runtime change. ### Testing Windows 10 Pro 19045, GTX 1050 Ti, NVIDIA 582.66, MSVC RelWithDebInfo, base `5fab93967`, 3 runs each way: - Over OpenSSH (session 0): `title_window` Skipped, `xgameruntime_offline` and `xgameruntime_offline_hdr` pass (on main all three fail there). - In an RDP desktop session on the same machine: all three pass with every check run. - `python -I scripts/check_no_game_data.py` on the changed files: clean. AI-assisted (Claude Code, Opus 5.5). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Over OpenSSH or as a service (session 0) the process's window station is
not interactive: no window is visible there, so find_title_window has
nothing to pick, and PowerSetRequest(PowerRequestDisplayRequired) answers
ERROR_NOT_SUPPORTED, so XDisplayAcquireTimeoutDeferral fails (measured on
Windows 10 19045 over SSH; the system and away-mode requests work there).
From a desktop session both tests pass (measured in an RDP session on the
same machine). title_window returns 77 (SKIP) without an interactive
station; xgameruntime_offline skips only its two display-deferral checks,
and only when the request is refused with ERROR_NOT_SUPPORTED there.
Both use window_station.h's has_interactive_window_station(), as the DXGI
tests do. #1217 documents the SSH difference.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 10:19:40 +00:00
Author
Owner

@⁠JordanWebDev on GitHub · 2026-11-25 23:41 UTC · original · approved these changes

**@⁠JordanWebDev** on GitHub · 2026-11-25 23:41 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/2139#pullrequestreview-6066538883) · **approved these changes**
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

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

Merge

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