Skip to content

Port upstream #335: a store id without an installed package is an invalid argument - #48

Merged
DesertGamer merged 1 commit into
DesertGamer:mainfrom
lcg007xd-c:port/upstream-335-store-id-invalid-arg
Nov 26, 2026
Merged

DesertGamer merged 1 commit into
DesertGamer:mainfrom
lcg007xd-c:port/upstream-335-store-id-invalid-arg

Conversation

@lcg007xd-c

Copy link
Copy Markdown
Contributor

What this changes

This ports Marvisak/VIctory#335 by marquezini. It is cherry-picked with -x, so the commit keeps their authorship.

XStoreQueryPackageIdentifier (package_identifier in crates/viport-hle/src/modules/xstore.rs) is documented to return E_INVALIDARG for a store id that has no installed package. VIPort returns XPackage's "could not resolve" error, 0x89245208 (xpackage::NO_PACKAGE), instead. A title that checks for the documented code takes the wrong branch.

VIPort has the upstream merge of #335 in its history, but the change is not in the tree. It was lost in a later merge.

Conflicts.

  • VIPort has since moved the lookup into installed_package. The port keeps that helper and changes only the code returned when it finds nothing.
  • VIPort's own test the_store_id_maps_to_the_installation (from d51dc42) was written against the old return value. Its two xpackage::NO_PACKAGE expectations become E_INVALIDARG. Its "nothing written" check is unchanged.
  • #335's test a_store_id_without_a_package_is_an_invalid_argument comes with it.

Checked

  • No game data of any kind (files, extracts, screenshots, dumps, saves): see docs/asset-policy.md
  • No binary files or archives
  • No new dependency, build.rs, git hook, .cargo config, CI change or script (or an issue explains why)
  • No download, no started program, no network connection added (or an issue explains why)
  • cargo test --workspace passes (not run, see below)
  • cargo clippy --workspace --all-targets --locked -- -D warnings passes (Windows target, run on Linux)
  • The code I wrote is formatted with rustfmt; I did not reformat lines I did not change

What I ran

cargo clippy --workspace --all-targets --locked --target x86_64-pc-windows-msvc -- -D warnings, cross-checked from Linux on this branch: clean. So the changed and new tests type-check.

Not run: cargo test -p viport-hle, which builds only for Windows. Both tests will run in the Windows CI test step.

Overlaps

None. No open PR touches viport-hle/src/modules/xstore.rs.

🤖 Generated with Claude Code

XStoreQueryPackageIdentifier documents E_INVALIDARG for a store id that
has no installed package. We returned XPackage's 0x89245208 instead.

(cherry picked from commit e3bef08)
@DesertGamer
DesertGamer merged commit eaf5dd2 into DesertGamer:main Nov 26, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants