feat: offline GDK interfaces (XGameStreaming, XGameUi, XNetworking, XAccessibility, XUser), unnotified subscriptions in E_NOTIMPL — 277/396 #231

Open
KainanP wants to merge 10 commits from upstream-pr/231 into main
KainanP commented 2026-11-25 19:49:05 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-25T19:49:05Z.


Supersedes #217 (closed by the maintainer for conflicts; rebased onto main 4f2cf5c as asked)

Only the README rows next to the RDNA 2 lines conflicted (main's RDNA 2 numbers kept, this PR's GDK lines kept). The last commit of #217 (README test count 1200+) is already on main, so the rebase dropped it; the suite collects 1,355 tests (1300+, already on main).

Change

New version of #156, as asked in the maintainer's closing note (https://github.com/LooperSalty/AnyXboxX/pull/156#issuecomment-7166165861): the offline GDK interfaces come back unchanged, and the change subscriptions that AnyXboxX never notifies now return E_NOTIMPL and are logged, instead of S_OK with a token.

Linked issue: Refs #156

  • Commits 1–5 are #156's commits, rebased on main (now a445308), their messages translated into English (rule 7): XGameStreaming with no streaming client, XGameUi handed to the game's own UI callbacks, the PC's network settings and high-contrast mode (XNetworking, XAccessibility), XUser devices (Windows' default communications audio endpoint, the all-zero controller id documented for PC).
  • Commit 7 (docs: cite the Microsoft Learn pages for the PC answers of the XNetworking queries, comment only) gives the source of the zero answers next to the code. XNetworkingConfigurationSetting says for each of the three settings: "Retrieving this setting on PC will always report the value 0". XNetworkingStatisticsType says for each of the three types: "On PC, all statistics in the structure are always reported as 0". Both functions return S_OK with these documented values, and an unknown setting or type returns E_INVALIDARG, as the function pages say.
  • Commit 6 (fix: change subscriptions that are never notified return E_NOTIMPL) is the rule 3 fix. XNetworkingRegisterConnectivityHintChanged and XUserRegisterForDefaultAudioEndpointUtf16Changed are wired to ANYXBOXX_NOT_IMPLEMENTED: E_NOTIMPL, the trace line [runtime] méthode d'interface non écrite appelée -> E_NOTIMPL with ANYXBOXX_TRACE=1, no token written. Their unregister functions return false (no registration can succeed). The queries (XNetworkingGetConnectivityHint, XUserGetDefaultAudioEndpointUtf16) still return the current value.
  • One addition to the two functions named in the closing note: XUserRegisterForDeviceAssociationChanged had the same pattern (S_OK, token, callback never called; it was in the first review of #156 next to the audio endpoint), so it returns E_NOTIMPL too. If you prefer it left as it was, it is one table line in user_device_interface.cpp and one test parameter to revert.
  • Last commit (fix: XGameStreamingRegisterConnectionStateChanged returns E_NOTIMPL), from the review: no streaming client ever connects, so this registration's callback could never run. Slot 12 is now ANYXBOXX_NOT_IMPLEMENTED in the C++ table and left to not_implemented in the Rust one (E_NOTIMPL, logged with ANYXBOXX_TRACE=1, no token written); XGameStreamingUnregisterConnectionStateChanged returns false in both. XGameStreamingGetConnectionState still answers Disconnected.
  • Because the four registrations are now ANYXBOXX_NOT_IMPLEMENTED in the tables, the GDK runtime counter drops from 280 to 276 of 396 (README in English and French, GDK parts of carte-avancee.svg and traduction.svg). docs/progress.md and docs/fr/avancee.md: the "Subscriptions" section lists the four, says E_NOTIMPL + log and cites the decision on #156.
  • Left as is (already on main, not part of this PR): XStoreRegisterGameLicenseChanged (the offline license never changes).
  • Images: only the GDK parts of carte-avancee.svg and traduction.svg are re-rendered (they depend on runtime/xgameruntime alone); the sections that need the game package stay as on main.

Verification

Windows 11 26200, Python 3.12, runtime built from this branch (VS 2022 Build Tools, CMake, cargo with the CI flags), rebased on main at a445308:

python -m ruff check --select W605,F,E9 PrototypeScarlett tests tools → All checks passed!
ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto (RTX 4060)       → 1991 passed, 1 skipped
  (incl. tests/test_rust_dlls.py, Rust-vs-C++ parity)
cargo test --release -p anyxboxx-xgameruntime                         → 87 passed
cargo clippy --release -p anyxboxx-xgameruntime --all-targets -- -D warnings → clean
cargo fmt -p anyxboxx-xgameruntime --check                            → clean

README test count (1900+) = collected tests rounded down (1992); GDK counter in the README = translation.gdk_runtime_area() (276).

Oracle and test data

  • Rule 3 tests: the four registrations return E_NOTIMPL and leave the caller's token untouched, the unregisters return false; a subprocess with ANYXBOXX_TRACE=1 calls each registration and checks the E_NOTIMPL line on stderr. They fail with the runtime built before commit 6 (the two streaming ones, before the last commit).
  • The rest is unchanged from #156: Microsoft Learn pages cited next to each function; Windows itself as the oracle (IMMDeviceEnumerator, Network List Manager, SPI_GETHIGHCONTRAST). All test data is built in the tests.

Checklist

  • The PR covers a single reviewable behaviour (the offline interfaces of #156, with the rule 3 fix).
  • A test fails without this change and passes with it.
  • The commands and results of each check are given above.
  • An unimplemented function returns an error (E_NOTIMPL), never a fake success.
  • README: the same change in English and French (test_readme_sync.py checks it).
  • No game, console or SDK file, no key, no dump, no download link.
  • Findings drawn from a title: none.
  • Code taken from another project: none.

Made with AI assistance (Claude Code, Claude Opus 5.5); tests run on the adapters above.

🤖 Generated with Claude Code

<!-- greyfinch-sync:LooperSalty/AnyXboxX:issue:5498070540 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-25T19:49:05Z. --- Supersedes #217 (closed by the maintainer for conflicts; rebased onto main 4f2cf5c as asked) Only the README rows next to the RDNA 2 lines conflicted (main's RDNA 2 numbers kept, this PR's GDK lines kept). The last commit of #217 (README test count `1200+`) is already on `main`, so the rebase dropped it; the suite collects 1,355 tests (`1300+`, already on `main`). ## Change New version of #156, as asked in the maintainer's closing note (https://github.com/LooperSalty/AnyXboxX/pull/156#issuecomment-7166165861): the offline GDK interfaces come back unchanged, and the change subscriptions that AnyXboxX never notifies now return `E_NOTIMPL` and are logged, instead of `S_OK` with a token. Linked issue: Refs #156 - Commits 1–5 are #156's commits, rebased on `main` (now `a445308`), their messages translated into English (rule 7): `XGameStreaming` with no streaming client, `XGameUi` handed to the game's own UI callbacks, the PC's network settings and high-contrast mode (`XNetworking`, `XAccessibility`), `XUser` devices (Windows' default communications audio endpoint, the all-zero controller id documented for PC). - Commit 7 (`docs: cite the Microsoft Learn pages for the PC answers of the XNetworking queries`, comment only) gives the source of the zero answers next to the code. [XNetworkingConfigurationSetting](https://learn.microsoft.com/en-us/gaming/gdk/docs/reference/networking/xnetworking/enums/xnetworkingconfigurationsetting) says for each of the three settings: "Retrieving this setting on PC will always report the value 0". [XNetworkingStatisticsType](https://learn.microsoft.com/en-us/gaming/gdk/docs/reference/networking/xnetworking/enums/xnetworkingstatisticstype) says for each of the three types: "On PC, all statistics in the structure are always reported as 0". Both functions return `S_OK` with these documented values, and an unknown setting or type returns `E_INVALIDARG`, as the function pages say. - Commit 6 (`fix: change subscriptions that are never notified return E_NOTIMPL`) is the rule 3 fix. `XNetworkingRegisterConnectivityHintChanged` and `XUserRegisterForDefaultAudioEndpointUtf16Changed` are wired to `ANYXBOXX_NOT_IMPLEMENTED`: `E_NOTIMPL`, the trace line `[runtime] méthode d'interface non écrite appelée -> E_NOTIMPL` with `ANYXBOXX_TRACE=1`, no token written. Their unregister functions return `false` (no registration can succeed). The queries (`XNetworkingGetConnectivityHint`, `XUserGetDefaultAudioEndpointUtf16`) still return the current value. - **One addition to the two functions named in the closing note:** `XUserRegisterForDeviceAssociationChanged` had the same pattern (`S_OK`, token, callback never called; it was in the first review of #156 next to the audio endpoint), so it returns `E_NOTIMPL` too. If you prefer it left as it was, it is one table line in `user_device_interface.cpp` and one test parameter to revert. - **Last commit (`fix: XGameStreamingRegisterConnectionStateChanged returns E_NOTIMPL`), from the review:** no streaming client ever connects, so this registration's callback could never run. Slot 12 is now `ANYXBOXX_NOT_IMPLEMENTED` in the C++ table and left to `not_implemented` in the Rust one (`E_NOTIMPL`, logged with `ANYXBOXX_TRACE=1`, no token written); `XGameStreamingUnregisterConnectionStateChanged` returns `false` in both. `XGameStreamingGetConnectionState` still answers `Disconnected`. - Because the four registrations are now `ANYXBOXX_NOT_IMPLEMENTED` in the tables, the GDK runtime counter drops from 280 to **276 of 396** (README in English and French, GDK parts of `carte-avancee.svg` and `traduction.svg`). `docs/progress.md` and `docs/fr/avancee.md`: the "Subscriptions" section lists the four, says `E_NOTIMPL` + log and cites the decision on #156. - Left as is (already on `main`, not part of this PR): `XStoreRegisterGameLicenseChanged` (the offline license never changes). - Images: only the GDK parts of `carte-avancee.svg` and `traduction.svg` are re-rendered (they depend on `runtime/xgameruntime` alone); the sections that need the game package stay as on `main`. ## Verification Windows 11 26200, Python 3.12, runtime built from this branch (VS 2022 Build Tools, CMake, cargo with the CI flags), rebased on `main` at `a445308`: ``` python -m ruff check --select W605,F,E9 PrototypeScarlett tests tools → All checks passed! ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto (RTX 4060) → 1991 passed, 1 skipped (incl. tests/test_rust_dlls.py, Rust-vs-C++ parity) cargo test --release -p anyxboxx-xgameruntime → 87 passed cargo clippy --release -p anyxboxx-xgameruntime --all-targets -- -D warnings → clean cargo fmt -p anyxboxx-xgameruntime --check → clean ``` README test count (`1900+`) = collected tests rounded down (1992); GDK counter in the README = `translation.gdk_runtime_area()` (276). ## Oracle and test data - Rule 3 tests: the four registrations return `E_NOTIMPL` and leave the caller's token untouched, the unregisters return `false`; a subprocess with `ANYXBOXX_TRACE=1` calls each registration and checks the `E_NOTIMPL` line on stderr. They fail with the runtime built before commit 6 (the two streaming ones, before the last commit). - The rest is unchanged from #156: Microsoft Learn pages cited next to each function; Windows itself as the oracle (IMMDeviceEnumerator, Network List Manager, SPI_GETHIGHCONTRAST). All test data is built in the tests. ## Checklist - [x] The PR covers a single reviewable behaviour (the offline interfaces of #156, with the rule 3 fix). - [x] A test fails without this change and passes with it. - [x] The commands and results of each check are given above. - [x] An unimplemented function returns an error (`E_NOTIMPL`), never a fake success. - [x] README: the same change in English and French (`test_readme_sync.py` checks it). - [x] No game, console or SDK file, no key, no dump, no download link. - [x] Findings drawn from a title: none. - [x] Code taken from another project: none. Made with AI assistance (Claude Code, Claude Opus 5.5); tests run on the adapters above. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
LooperSalty commented 2026-11-25 21:03:11 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-25T21:03:11Z.


Thanks, the offline interfaces return E_NOTIMPL or log where unimplemented, as rule 3 asks.

Some commit messages are in French (for example "docs: abonnements sans notification décrits ..." and "feat: XUser et périphériques ..."). Please reword them in English, or squash to an English message, per rule 7. If the zero-value answers of XNetworkingQueryConfigurationSetting and XNetworkingQueryStatistics come from a Microsoft Learn page, please cite it next to the code.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7174544424 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7174544424). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-25T21:03:11Z. --- Thanks, the offline interfaces return E_NOTIMPL or log where unimplemented, as rule 3 asks. Some commit messages are in French (for example "docs: abonnements sans notification décrits ..." and "feat: XUser et périphériques ..."). Please reword them in English, or squash to an English message, per rule 7. If the zero-value answers of XNetworkingQueryConfigurationSetting and XNetworkingQueryStatistics come from a Microsoft Learn page, please cite it next to the code.
LooperSalty commented 2026-11-25 21:45:39 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-25T21:45:39Z.


Follow-up after the review: the Leonida point is fine now, thanks. Five of the six commit messages are still in French (91a80512, 3ac35273, 1850abd6, 52b6d6f8, 2cd5b95a); please reword them in English (type: description) or squash into one English commit (rule 7), and rebase on main.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7175503987 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7175503987). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-25T21:45:39Z. --- Follow-up after the review: the Leonida point is fine now, thanks. Five of the six commit messages are still in French (91a80512, 3ac35273, 1850abd6, 52b6d6f8, 2cd5b95a); please reword them in English (`type: description`) or squash into one English commit (rule 7), and rebase on main.
KainanP commented 2026-11-25 22:53:18 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-25T22:53:18Z.


Thanks. Updated and rebased on main e921268 (head bd9f16b):

  • All commit messages are now in English, as type: description. Commits 1-5 (feat: offline XGameStreaming…, feat: XGameUi without a system UI…, feat: PC network settings and high contrast…, feat: XUser devices…, docs: describe the subscriptions without notification…) are translations of the French originals, with author KainanP (noreply address) and the Co-Authored-By trailer.
  • New commit 7 (comment only) puts the Microsoft Learn source next to the code. XNetworkingConfigurationSetting says for each of the three settings: "Retrieving this setting on PC will always report the value 0." XNetworkingStatisticsType says for each type: "On PC, all statistics in the structure are always reported as 0." So the two queries return documented values (S_OK, E_INVALIDARG for an unknown setting or type), not a fake success.
  • README conflicts resolved: main's RDNA 2 figures kept, GDK 277/396, tests still 1400+.

Checks: full suite on the RTX 4060 → 1423 passed, 17 skipped (on 9a06443; the later rebase onto e921268 only brings #263's launcher test; test_readme_sync passes, 1,441 tests collected → 1400+) (runtime rebuilt from this branch); ruff clean.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7176902340 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7176902340). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-25T22:53:18Z. --- Thanks. Updated and rebased on main `e921268` (head `bd9f16b`): - All commit messages are now in English, as `type: description`. Commits 1-5 (`feat: offline XGameStreaming…`, `feat: XGameUi without a system UI…`, `feat: PC network settings and high contrast…`, `feat: XUser devices…`, `docs: describe the subscriptions without notification…`) are translations of the French originals, with author KainanP (noreply address) and the Co-Authored-By trailer. - New commit 7 (comment only) puts the Microsoft Learn source next to the code. [XNetworkingConfigurationSetting](https://learn.microsoft.com/en-us/gaming/gdk/docs/reference/networking/xnetworking/enums/xnetworkingconfigurationsetting) says for each of the three settings: "Retrieving this setting on PC will always report the value 0." [XNetworkingStatisticsType](https://learn.microsoft.com/en-us/gaming/gdk/docs/reference/networking/xnetworking/enums/xnetworkingstatisticstype) says for each type: "On PC, all statistics in the structure are always reported as 0." So the two queries return documented values (`S_OK`, `E_INVALIDARG` for an unknown setting or type), not a fake success. - README conflicts resolved: main's RDNA 2 figures kept, GDK 277/396, tests still 1400+. Checks: full suite on the RTX 4060 → 1423 passed, 17 skipped (on `9a06443`; the later rebase onto `e921268` only brings #263's launcher test; `test_readme_sync` passes, 1,441 tests collected → 1400+) (runtime rebuilt from this branch); ruff clean. _AI use: Claude Code (Claude Opus 5.5)._
LooperSalty commented 2026-11-26 00:06:48 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-26T00:06:48Z.


Thanks for rewording the commits in English. One thing left: docs/images/carte-avancee.svg and traduction.svg still show 210/396; AGENTS.md asks to regenerate them with scarlett.py --carte .. and --traduction .. when the counts move. Also commit 1dd46828 says "8 languages" where 9 READMEs are concerned. Then it is ready.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7178408389 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7178408389). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-26T00:06:48Z. --- Thanks for rewording the commits in English. One thing left: `docs/images/carte-avancee.svg` and `traduction.svg` still show 210/396; AGENTS.md asks to regenerate them with `scarlett.py --carte ..` and `--traduction ..` when the counts move. Also commit 1dd46828 says "8 languages" where 9 READMEs are concerned. Then it is ready.
KainanP commented 2026-11-26 09:07:20 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-26T09:07:20Z.


Rebased onto main c4c93bd after #230/#232/#235 merged (head 08d8568); README recounted from the code: GDK runtime 277/396 in the 9 READMEs (main's text kept, only the GDK sentence and row changed), RDNA 2 line unchanged at main's 1,285/1,490, test count stays 1600+.

Your two points:

  • docs/images/carte-avancee.svg and traduction.svg: new commit 08d8568 re-renders their GDK parts with emu.status_map / emu.translation on runtime/xgameruntime (GDK badge, GDK section of the map, GDK row of the chart): 277/396, 30/34 interfaces. These parts depend only on the runtime sources. The other sections need the game package, which I don't have here, so they stay as on main. As a check, the same rendering from main's runtime sources gives main's images byte for byte.
  • Commit f08749c (was 1dd46828) now says "README in 9 languages".

Tests: test_readme_sync, the four runtime test files of this PR, test_status_map, test_translation, test_gdk_interfaces, test_gdk_boot: 88 passed, 1 skipped; ruff clean. No code changed during the rebase (conflicts were README lines only), so I did not rerun the full suite.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7187455025 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7187455025). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-26T09:07:20Z. --- Rebased onto main `c4c93bd` after #230/#232/#235 merged (head `08d8568`); README recounted from the code: GDK runtime 277/396 in the 9 READMEs (main's text kept, only the GDK sentence and row changed), RDNA 2 line unchanged at main's 1,285/1,490, test count stays 1600+. Your two points: - `docs/images/carte-avancee.svg` and `traduction.svg`: new commit `08d8568` re-renders their GDK parts with `emu.status_map` / `emu.translation` on `runtime/xgameruntime` (GDK badge, GDK section of the map, GDK row of the chart): 277/396, 30/34 interfaces. These parts depend only on the runtime sources. The other sections need the game package, which I don't have here, so they stay as on main. As a check, the same rendering from main's runtime sources gives main's images byte for byte. - Commit `f08749c` (was `1dd46828`) now says "README in 9 languages". Tests: `test_readme_sync`, the four runtime test files of this PR, `test_status_map`, `test_translation`, `test_gdk_interfaces`, `test_gdk_boot`: 88 passed, 1 skipped; ruff clean. No code changed during the rebase (conflicts were README lines only), so I did not rerun the full suite. _AI use: Claude Code (Claude Opus 5.5)._
KainanP commented 2026-11-26 13:02:44 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-26T13:02:44Z.


Merged main (b5a9d10, with #351) into the branch and ported this PR's interfaces to the Rust runtime (head f494613).

With #351, tests/test_rust_dlls.py runs the runtime test files against crates/anyxboxx-xgameruntime too. Before the port, the Rust DLL answered E_NOTIMPL for everything this PR adds, so that test failed (15 failed, 8 errors inside it). Commit 68c1d51 ports the same behaviour to the crate, following the approach #351 used for the existing interfaces (one module per interface, registered in served.rs):

  • streaming.rs: XGameStreaming with no streaming client (documented E_GAMESTREAMING_* codes, display-details checks; XGameStreamingSetResolution stays E_NOTIMPL).
  • gameui.rs, gameui_input.rs, gameui_responses.rs, gameui_requests.rs: XGameUi screens are handed to the game's callbacks through VIctory's xasync. When the game gave no callback, the call returns E_NOTIMPL and is logged.
  • accessibility.rs: XHighContrastGetMode reads Windows' real setting. Captions and speech stay E_NOTIMPL.
  • user_device.rs: Windows' default communications endpoint and the all-zero controller id on PC. XUserRegisterForDeviceAssociationChanged and XUserRegisterForDefaultAudioEndpointUtf16Changed return E_NOTIMPL and are logged.
  • networking.rs: TCP buffer settings and statistics. The Microsoft Learn quotes for XNetworkingConfigurationSetting and XNetworkingStatisticsType ("always 0 on PC") sit next to the code, as in the C++. XNetworkingRegisterConnectivityHintChanged now returns E_NOTIMPL and is logged on the Rust side too. Main's Rust port still accepted that subscription without ever notifying it.

The C++ side is unchanged (main still builds it as the oracle). docs/rust-full-status.md and its French version mention the port.

Figures: gdk_runtime_area() still reads the C++ tables. Those tables and the Rust tables now give the same answers, and test_rust_dlls checks that they match. The count stays 277/396 (30/34 interfaces) and the README count stays 1800+ (1,835 tests collected). No README or image change.

Checks on the RTX 4060, after building Rust with the CI profile and runtime/ with CMake:

  • ANYXBOXX_REQUIRE_RUNTIME=1 pytest -n auto → 1834 passed, 1 skipped.
  • The runtime and GDK test files against the Rust DLL → 113 passed.
  • cargo test --release -p anyxboxx-xgameruntime → 81 passed; cargo test --release --workspace passes.
  • cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings, cargo fmt --check and ruff are clean.

These results are from 68c1d51. The last main merge only brings .gitattributes (#359).

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7192798968 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7192798968). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-26T13:02:44Z. --- Merged main (`b5a9d10`, with #351) into the branch and ported this PR's interfaces to the Rust runtime (head `f494613`). With #351, `tests/test_rust_dlls.py` runs the runtime test files against `crates/anyxboxx-xgameruntime` too. Before the port, the Rust DLL answered `E_NOTIMPL` for everything this PR adds, so that test failed (15 failed, 8 errors inside it). Commit `68c1d51` ports the same behaviour to the crate, following the approach #351 used for the existing interfaces (one module per interface, registered in `served.rs`): - `streaming.rs`: `XGameStreaming` with no streaming client (documented `E_GAMESTREAMING_*` codes, display-details checks; `XGameStreamingSetResolution` stays `E_NOTIMPL`). - `gameui.rs`, `gameui_input.rs`, `gameui_responses.rs`, `gameui_requests.rs`: `XGameUi` screens are handed to the game's callbacks through VIctory's `xasync`. When the game gave no callback, the call returns `E_NOTIMPL` and is logged. - `accessibility.rs`: `XHighContrastGetMode` reads Windows' real setting. Captions and speech stay `E_NOTIMPL`. - `user_device.rs`: Windows' default communications endpoint and the all-zero controller id on PC. `XUserRegisterForDeviceAssociationChanged` and `XUserRegisterForDefaultAudioEndpointUtf16Changed` return `E_NOTIMPL` and are logged. - `networking.rs`: TCP buffer settings and statistics. The Microsoft Learn quotes for `XNetworkingConfigurationSetting` and `XNetworkingStatisticsType` ("always 0 on PC") sit next to the code, as in the C++. `XNetworkingRegisterConnectivityHintChanged` now returns `E_NOTIMPL` and is logged on the Rust side too. Main's Rust port still accepted that subscription without ever notifying it. The C++ side is unchanged (main still builds it as the oracle). `docs/rust-full-status.md` and its French version mention the port. Figures: `gdk_runtime_area()` still reads the C++ tables. Those tables and the Rust tables now give the same answers, and `test_rust_dlls` checks that they match. The count stays 277/396 (30/34 interfaces) and the README count stays 1800+ (1,835 tests collected). No README or image change. Checks on the RTX 4060, after building Rust with the CI profile and `runtime/` with CMake: - `ANYXBOXX_REQUIRE_RUNTIME=1 pytest -n auto` → 1834 passed, 1 skipped. - The runtime and GDK test files against the Rust DLL → 113 passed. - `cargo test --release -p anyxboxx-xgameruntime` → 81 passed; `cargo test --release --workspace` passes. - `cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings`, `cargo fmt --check` and ruff are clean. These results are from `68c1d51`. The last main merge only brings `.gitattributes` (#359). _AI use: Claude Code (Claude Opus 5.5)._
KainanP commented 2026-11-26 16:21:17 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-26T16:21:17Z.


Rebased onto main ce0f90f (after #343 and #252), head e504a09: ten linear commits, the two merge commits are gone (previous head kept locally as tag pre-rebase-231c).

  • Conflicts were only in the 9 READMEs (main's RDNA 2 and VIctory lines next to this PR's GDK lines): main's text kept, this PR's GDK sentence and row put back. The branch's diff against main is the same as before the rebase.
  • GDK runtime still 277 of 396 (gdk_runtime_area(), 30/34 interfaces). New commit e504a09 moves the test count to 1900+ (1,922 collected).
  • Checks: full suite on RTX (ANYXBOXX_REQUIRE_RUNTIME=1, pytest -n auto) 1921 passed, 1 skipped, Rust xgameruntime parity (test_rust_dlls.py) included; cargo test -p anyxboxx-xgameruntime 85 passed; cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings clean; ruff (W605,F,E9) clean.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7197531658 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7197531658). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-26T16:21:17Z. --- Rebased onto main `ce0f90f` (after #343 and #252), head `e504a09`: ten linear commits, the two merge commits are gone (previous head kept locally as tag `pre-rebase-231c`). - Conflicts were only in the 9 READMEs (main's RDNA 2 and VIctory lines next to this PR's GDK lines): main's text kept, this PR's GDK sentence and row put back. The branch's diff against main is the same as before the rebase. - GDK runtime still **277 of 396** (`gdk_runtime_area()`, 30/34 interfaces). New commit `e504a09` moves the test count to **1900+** (1,922 collected). - Checks: full suite on RTX (`ANYXBOXX_REQUIRE_RUNTIME=1`, `pytest -n auto`) 1921 passed, 1 skipped, Rust xgameruntime parity (`test_rust_dlls.py`) included; `cargo test -p anyxboxx-xgameruntime` 85 passed; `cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings` clean; ruff (W605,F,E9) clean. _AI use: Claude Code (Claude Opus 5.5)._
KainanP commented 2026-11-26 18:26:06 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-26T18:26:06Z.


Rebased onto main 8e32daa (after #407), head 3985aac (previous head kept locally as tag pre-rebase4-231).

  • The only conflicts were in the READMEs. Main now keeps English and French only, with a shorter GDK sentence, so the per-commit README edits take main's text. One new commit, 3985aac, puts this PR's figure back in both READMEs and lists the interfaces it serves (streaming, system dialogs, network settings, high contrast, audio devices). The old "test count 1900+" commit became empty and was dropped, because main already says 1900+.
  • GDK runtime: gdk_runtime_area() gives 277 of 396 (30/34 interfaces) on the rebased tree, against 210/396 (26/34) on main. The progress map and translation chart match. Test count 1900+ (1,930 collected).
  • Checks: full suite on RTX (ANYXBOXX_REQUIRE_RUNTIME=1, pytest -n auto) 1929 passed, 1 skipped, with the Rust xgameruntime parity tests (test_rust_dlls.py). cargo test --release -p anyxboxx-xgameruntime 87 passed. cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings, cargo fmt --check and ruff (W605,F,E9) are clean.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7200458920 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7200458920). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-26T18:26:06Z. --- Rebased onto main `8e32daa` (after #407), head `3985aac` (previous head kept locally as tag `pre-rebase4-231`). - The only conflicts were in the READMEs. Main now keeps English and French only, with a shorter GDK sentence, so the per-commit README edits take main's text. One new commit, `3985aac`, puts this PR's figure back in both READMEs and lists the interfaces it serves (streaming, system dialogs, network settings, high contrast, audio devices). The old "test count 1900+" commit became empty and was dropped, because main already says 1900+. - GDK runtime: `gdk_runtime_area()` gives **277 of 396** (30/34 interfaces) on the rebased tree, against 210/396 (26/34) on main. The progress map and translation chart match. Test count 1900+ (1,930 collected). - Checks: full suite on RTX (`ANYXBOXX_REQUIRE_RUNTIME=1`, `pytest -n auto`) 1929 passed, 1 skipped, with the Rust xgameruntime parity tests (`test_rust_dlls.py`). `cargo test --release -p anyxboxx-xgameruntime` 87 passed. `cargo clippy -p anyxboxx-xgameruntime --all-targets -- -D warnings`, `cargo fmt --check` and ruff (W605,F,E9) are clean. _AI use: Claude Code (Claude Opus 5.5)._
LooperSalty commented 2026-11-27 16:24:25 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-27T16:24:25Z.


One point on rule 3 before merge: XGameStreamingRegisterConnectionStateChanged (crates/anyxboxx-xgameruntime/src/streaming.rs, register_connection_state_changed) returns S_OK and a token through events::add_subscription, but its callback can never run. That is the "registration that succeeds and never notifies" case we turned into E_NOTIMPL elsewhere (#156), and the three other registrations in this PR follow it. Please either return E_NOTIMPL with a log here too, or say in the description why a connection-state registration is different (for example a measured title that fails on E_NOTIMPL here). The rest of the interface answers (disconnected, PC values from Microsoft Learn) look fine.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7223223891 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7223223891). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-27T16:24:25Z. --- One point on rule 3 before merge: `XGameStreamingRegisterConnectionStateChanged` (`crates/anyxboxx-xgameruntime/src/streaming.rs`, `register_connection_state_changed`) returns `S_OK` and a token through `events::add_subscription`, but its callback can never run. That is the "registration that succeeds and never notifies" case we turned into `E_NOTIMPL` elsewhere (#156), and the three other registrations in this PR follow it. Please either return `E_NOTIMPL` with a log here too, or say in the description why a connection-state registration is different (for example a measured title that fails on `E_NOTIMPL` here). The rest of the interface answers (disconnected, PC values from Microsoft Learn) look fine.
KainanP commented 2026-11-27 16:53:20 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-27T16:53:20Z.


Done: XGameStreamingRegisterConnectionStateChanged now returns E_NOTIMPL + log like the other three (slot 12 is ANYXBOXX_NOT_IMPLEMENTED in C++ and not_implemented in Rust, no token written; the unregister returns false). Tests: the streaming subscription test expects E_NOTIMPL with an untouched token, and the ANYXBOXX_TRACE=1 test covers slot 12. GDK counter 277 → 276/396 (README EN/FR, GDK parts of the two images, docs list the four subscriptions). Rebased on main a445308; full suite 1991 passed / 1 skipped on the RTX 4060 (incl. Rust-vs-C++ parity), cargo test/clippy/fmt clean. Commit 0048145.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7223785597 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7223785597). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-27T16:53:20Z. --- Done: `XGameStreamingRegisterConnectionStateChanged` now returns `E_NOTIMPL` + log like the other three (slot 12 is `ANYXBOXX_NOT_IMPLEMENTED` in C++ and `not_implemented` in Rust, no token written; the unregister returns `false`). Tests: the streaming subscription test expects `E_NOTIMPL` with an untouched token, and the `ANYXBOXX_TRACE=1` test covers slot 12. GDK counter 277 → 276/396 (README EN/FR, GDK parts of the two images, docs list the four subscriptions). Rebased on `main` `a445308`; full suite 1991 passed / 1 skipped on the RTX 4060 (incl. Rust-vs-C++ parity), cargo test/clippy/fmt clean. Commit `0048145`. _AI use: Claude Code (Claude Opus 5.5)._
KainanP commented 2026-11-27 19:30:17 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-27T19:30:17Z.


Rebased onto main 3e3dd53e; head is now 31b72380.

  • Kept both sides in the xgameruntime Cargo.toml (main's Win32_System_Environment, our Win32_Graphics_Gdi).
  • Took main's README and status text, then updated it to the merged inventory: 263 of 396 GDK functions, 30 of 34 interfaces. unsupported.txt now lists the generic refusals of the four new interfaces, including the change subscriptions that are never notified. It also lists XNetworkingSetConfigurationSetting as an explicit PC refusal. The TCP buffer query and the statistics come off the list. test_rust_xgameruntime_parity.py now checks 30 pairs. Only the GDK parts of both images were regenerated.
  • Passed: cargo build/test --release -p anyxboxx-xgameruntime (87 tests), clippy -D warnings, fmt --check and ruff. With ANYXBOXX_REQUIRE_RUNTIME=1, these also passed: test_rust_xgameruntime_parity.py, test_rust_dlls.py, test_rust_carte_parity.py, the gameui, streaming, user_device and platform runtime tests, and test_readme_sync.py. Full suite on 31b72380: ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto → 1996 passed, 0 skipped (includes test_rust_dlls.py).

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7226592117 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7226592117). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-27T19:30:17Z. --- Rebased onto main 3e3dd53e; head is now 31b72380. - Kept both sides in the xgameruntime `Cargo.toml` (main's `Win32_System_Environment`, our `Win32_Graphics_Gdi`). - Took main's README and status text, then updated it to the merged inventory: 263 of 396 GDK functions, 30 of 34 interfaces. `unsupported.txt` now lists the generic refusals of the four new interfaces, including the change subscriptions that are never notified. It also lists `XNetworkingSetConfigurationSetting` as an explicit PC refusal. The TCP buffer query and the statistics come off the list. `test_rust_xgameruntime_parity.py` now checks 30 pairs. Only the GDK parts of both images were regenerated. - Passed: `cargo build`/`test --release -p anyxboxx-xgameruntime` (87 tests), clippy `-D warnings`, `fmt --check` and ruff. With `ANYXBOXX_REQUIRE_RUNTIME=1`, these also passed: `test_rust_xgameruntime_parity.py`, `test_rust_dlls.py`, `test_rust_carte_parity.py`, the gameui, streaming, user_device and platform runtime tests, and `test_readme_sync.py`. Full suite on 31b72380: `ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto` → 1996 passed, 0 skipped (includes `test_rust_dlls.py`). _AI use: Claude Code (Claude Opus 5.5)._
LooperSalty commented 2026-11-27 19:30:23 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-27T19:30:23Z.


Thanks! #538 has just been merged: the shipped xgameruntime.dll is now the Rust one (crates/anyxboxx-xgameruntime), and the C++ DLL only remains as the parity oracle. The GDK functions this PR adds to the C++ runtime would therefore not be shipped. Could you port them to the Rust crate (keeping the C++ side only if the parity tests need it) and rebase on main? The rest of the ready PRs went in through #545.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7226593888 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7226593888). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-27T19:30:23Z. --- Thanks! #538 has just been merged: the shipped `xgameruntime.dll` is now the Rust one (`crates/anyxboxx-xgameruntime`), and the C++ DLL only remains as the parity oracle. The GDK functions this PR adds to the C++ runtime would therefore not be shipped. Could you port them to the Rust crate (keeping the C++ side only if the parity tests need it) and rebase on main? The rest of the ready PRs went in through #545.
KainanP commented 2026-11-27 19:53:57 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by KainanP on 2026-11-27T19:53:57Z.


Rebased onto main ec3b7348 (after #545). The head is now dd00e22f.

The interfaces were already in the Rust crate. The earlier rebase onto #538 included commit 8f68a212, "port the offline GDK interfaces to the Rust xgameruntime". So the xgameruntime.dll that ships already serves all four new pairs from crates/anyxboxx-xgameruntime/src/:

  • streaming.rs
  • gameui.rs with gameui_input.rs, gameui_requests.rs and gameui_responses.rs
  • accessibility.rs
  • user_device.rs
  • the TCP buffer settings in networking.rs

They give the same answers as before. The four change subscriptions that are never notified still return E_NOTIMPL + log, with no token written. The Microsoft Learn citations stay next to the Rust code.

Why the C++ side is kept. The parity tests from #538 need it:

  • test_rust_dlls.py::test_runtime_suite[cpp] runs every test_runtime_*.py (including the new gameui, streaming, user_device and platform tests) against the C++ oracle.
  • test_rust_xgameruntime_parity.py builds its interface matrix from served_interfaces.inc / gdk_api_table.inc. It expects 30 pairs, the same stub placement and rust == cpp, and it checks the result against unsupported.txt.
  • gdk_runtime_area() counts from the same C++ tables.

Without the C++ handlers, the oracle would stop matching and those tests would fail. The C++ files are now used only as the oracle. docs/rust-full-status.md (EN/FR) says that and names the Rust files that ship.

What changed in this rebase:

  • It applied with no conflicts.
  • I recomputed gdk_runtime_area() on the merged tree: still 263/396, 30/34 interfaces. So README, unsupported.txt and the GDK parts of both images stay as they were.
  • The README test count is now 2000+ (2006 collected).

Tests on dd00e22f:

  • Built per CI: cargo with the CI flags, then the CMake runtime/rust_dlls step. The installed DLL is byte-identical to target/release.
  • ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto: 2006 passed, 0 skipped. This includes test_rust_dlls.py (rust + cpp), test_rust_xgameruntime_parity.py and test_readme_sync.py.
  • cargo test --release -p anyxboxx-xgameruntime: 87 passed.
  • clippy -D warnings and fmt --check are clean.
  • ruff (CI rules) is clean.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7226977473 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/231#issuecomment-7226977473). Originally posted by [KainanP](https://github.com/KainanP) on 2026-11-27T19:53:57Z. --- Rebased onto `main` `ec3b7348` (after #545). The head is now `dd00e22f`. **The interfaces were already in the Rust crate.** The earlier rebase onto #538 included commit `8f68a212`, "port the offline GDK interfaces to the Rust xgameruntime". So the `xgameruntime.dll` that ships already serves all four new pairs from `crates/anyxboxx-xgameruntime/src/`: - `streaming.rs` - `gameui.rs` with `gameui_input.rs`, `gameui_requests.rs` and `gameui_responses.rs` - `accessibility.rs` - `user_device.rs` - the TCP buffer settings in `networking.rs` They give the same answers as before. The four change subscriptions that are never notified still return `E_NOTIMPL` + log, with no token written. The Microsoft Learn citations stay next to the Rust code. **Why the C++ side is kept.** The parity tests from #538 need it: - `test_rust_dlls.py::test_runtime_suite[cpp]` runs every `test_runtime_*.py` (including the new gameui, streaming, user_device and platform tests) against the C++ oracle. - `test_rust_xgameruntime_parity.py` builds its interface matrix from `served_interfaces.inc` / `gdk_api_table.inc`. It expects 30 pairs, the same stub placement and `rust == cpp`, and it checks the result against `unsupported.txt`. - `gdk_runtime_area()` counts from the same C++ tables. Without the C++ handlers, the oracle would stop matching and those tests would fail. The C++ files are now used only as the oracle. `docs/rust-full-status.md` (EN/FR) says that and names the Rust files that ship. **What changed in this rebase:** - It applied with no conflicts. - I recomputed `gdk_runtime_area()` on the merged tree: still 263/396, 30/34 interfaces. So README, `unsupported.txt` and the GDK parts of both images stay as they were. - The README test count is now 2000+ (2006 collected). **Tests on `dd00e22f`:** - Built per CI: cargo with the CI flags, then the CMake runtime/`rust_dlls` step. The installed DLL is byte-identical to `target/release`. - `ANYXBOXX_REQUIRE_RUNTIME=1 python -m pytest -n auto`: 2006 passed, 0 skipped. This includes `test_rust_dlls.py` (rust + cpp), `test_rust_xgameruntime_parity.py` and `test_readme_sync.py`. - `cargo test --release -p anyxboxx-xgameruntime`: 87 passed. - clippy `-D warnings` and `fmt --check` are clean. - ruff (CI rules) is clean. _AI use: Claude Code (Claude Opus 5.5)._
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/231:upstream-pr/231'
git switch 'upstream-pr/231'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/231'
git switch 'upstream-pr/231'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/231'
git switch 'upstream-pr/231'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/231'
git switch 'main'
git merge --squash 'upstream-pr/231'
git switch 'main'
git merge --ff-only 'upstream-pr/231'
git switch 'main'
git merge 'upstream-pr/231'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
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.

Reference
LooperSalty/AnyXboxX!231
No description provided.