Skip to content

Fix msstore manifest resolution and support msstore package installs - #62

Merged
Marc-André Moreau (mamoreau-devolutions) merged 3 commits into
masterfrom
copilot/fix-msstore-unknown-version-manifest
Nov 5, 2026
Merged

Marc-André Moreau (mamoreau-devolutions) merged 3 commits into
masterfrom
copilot/fix-msstore-unknown-version-manifest

Conversation

@mamoreau-devolutions

Copy link
Copy Markdown
Contributor

Summary

Fixes pinget install <msstore-id> (e.g. pinget install 9WZDNCRFJB3H) failing with 404 Not Found on /packageManifests/{id}?Version=Unknown&Market=US and completes end-to-end Microsoft Store (msstore) package resolution, installation, listing, and uninstallation across both the Rust and C# implementations.

Root Cause

  1. REST packageManifests query parameters: Microsoft Store's msstore (StoreEdgeFD) endpoint returns "PackageVersion": "Unknown" in manifestSearch results. When resolving the manifest, pinget sent Version=Unknown in the query string to /packageManifests/{id}, which StoreEdgeFD rejects with 404 Not Found. In C#, RestSource.FetchManifestWithDocuments also did not include RequiredQueryParameters (such as Market=US) or fall back to the version entry in Data.Versions when the concrete manifest version differed from "Unknown".
  2. msstore installer and agreement handling: msstore manifests use InstallerType: "msstore" with MSStoreProductIdentifier (no InstallerUrl) and include store package agreements in DefaultLocale.Agreements. Previously, pinget failed when InstallerUrl was absent, did not prompt interactively for package agreements in terminal sessions, and did not correlate installed MSIX packages against REST PackageFamilyNames.

Changes

  • REST manifest requests & parsing (Rust & C#):
    • Omit Version from /packageManifests/{id} query parameters when empty, "Unknown", or listed in UnsupportedQueryParameters.
    • Omit unsupported Channel and append Market when required by RequiredQueryParameters.
    • Resolve the selected entry's actual PackageVersion, Channel, and DefaultLocale from Data.Versions when manifestSearch returned "Unknown".
  • Version ordering:
    • Treat "Unknown" as the lowest version (Unknown < x) in version comparisons while keeping --include-unknown gating for upgrade discovery.
  • msstore installation, show, & correlation:
    • Parse MSStoreProductIdentifier across REST and YAML manifests, structured output, and show output (Store Product Id and Agreements).
    • Dispatch msstore installs via Windows.ApplicationModel.Store.Preview.InstallControl.AppInstallManager (policy check, free user/device entitlement acquisition, product install, and machine-scope provisioning) without requiring an InstallerUrl download.
    • Correlate installed MSIX/ARP packages using REST PackageFamilyNames, ProductCodes, and UpgradeCodes.
    • Prompt interactively for package agreements when running in a terminal without --accept-package-agreements.

Validation

  • cargo +nightly fmt --manifest-path rust\Cargo.toml --all
  • cargo clippy -q --manifest-path rust\Cargo.toml --workspace --tests -- -D warnings
  • cargo test -p pinget-core --manifest-path rust\Cargo.toml
  • cargo test -p pinget-cli --manifest-path rust\Cargo.toml
  • dotnet build dotnet\Devolutions.Pinget.slnx -c Release
  • dotnet test dotnet\src\Devolutions.Pinget.Core.Tests\Devolutions.Pinget.Core.Tests.csproj -c Release
  • End-to-end verified show, install, list, and uninstall of 9WZDNCRFJB3H in both Rust and C# CLIs.

@mamoreau-devolutions
Marc-André Moreau (mamoreau-devolutions) force-pushed the copilot/fix-msstore-unknown-version-manifest branch from 1a79bd3 to aff40c0 Compare November 5, 2026 18:53
@mamoreau-devolutions
Marc-André Moreau (mamoreau-devolutions) merged commit f41f5c2 into master Nov 5, 2026
14 checks passed
@mamoreau-devolutions
Marc-André Moreau (mamoreau-devolutions) deleted the copilot/fix-msstore-unknown-version-manifest branch November 5, 2026 20:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant