XGameRuntime: XPackageEnumerateChunkAvailability never calls the callback #2775

Open
opened 2026-11-26 12:29:21 +00:00 by Amongus6969 · 1 comment
Amongus6969 commented 2026-11-26 12:29:21 +00:00 (Migrated from github.com)
Contributor

Imported from ivall/xcl. Originally posted by Amongus6969 on 2026-11-26T12:29:21Z.


On b49be18, XCL maps XPackageEnumerateChunkAvailability to ok(), which only returns S_OK. The GDK contract calls for one callback per matching selector. A caller listing available languages therefore gets an empty list even when the package has a matching language chunk.

Suggested regression test: Use a synthetic package with one installed chunk matching the requested selector. Verify that the callback runs once with that selector and Ready. If no chunk matches, verify that the callback does not run.

Verification: Source inspection only; no test or game was run.
AI use (source review and drafting): omp with openai-codex/gpt-6.2-astra checked the source and drafted this issue.

<!-- greyfinch-sync:ivall/xcl:issue:6626664204 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/issues/2785). Originally posted by [Amongus6969](https://github.com/Amongus6969) on 2026-11-26T12:29:21Z. --- On `b49be18`, XCL [maps `XPackageEnumerateChunkAvailability` to `ok()`](https://github.com/xcl-dev/xcl/blob/b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7/crates/xcl/src/hle/xgameruntime/api.rs#L837-L843), which [only returns `S_OK`](https://github.com/xcl-dev/xcl/blob/b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7/crates/xcl/src/hle/xgameruntime/api.rs#L937-L939). The [GDK contract](https://learn.microsoft.com/en-us/gaming/gdk/docs/reference/system/xpackage/functions/xpackageenumeratechunkavailability) calls for one callback per matching selector. A caller listing available languages therefore gets an empty list even when the package has a matching language chunk. **Suggested regression test:** Use a synthetic package with one installed chunk matching the requested selector. Verify that the callback runs once with that selector and `Ready`. If no chunk matches, verify that the callback does not run. **Verification:** Source inspection only; no test or game was run. **AI use (source review and drafting):** `omp` with `openai-codex/gpt-6.2-astra` checked the source and drafted this issue.
oni-swr commented 2026-11-26 13:05:40 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-26T12:37:36Z.


Claiming this: I'm making XPackageEnumerateChunkAvailability call the callback for each matching selector, with a regression test. A draft PR will follow.
AI-assisted (Claude Code, Claude Sonnet 5.5).

<!-- greyfinch-sync:ivall/xcl:comment:7192246990 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/issues/2785#issuecomment-7192246990). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-26T12:37:36Z. --- Claiming this: I'm making XPackageEnumerateChunkAvailability call the callback for each matching selector, with a regression test. A draft PR will follow. AI-assisted (Claude Code, Claude Sonnet 5.5).
Sign in to join this conversation.
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
xcl-dev/xcl#2775
No description provided.