Skip to content

Validate manifest installdir and recover install path via steam_appid probe#38

Open
weter11 wants to merge 1 commit into
mainfrom
codex/verify-install-path-and-fallback-scan
Open

Validate manifest installdir and recover install path via steam_appid probe#38
weter11 wants to merge 1 commit into
mainfrom
codex/verify-install-path-and-fallback-scan

Conversation

@weter11
Copy link
Copy Markdown
Owner

@weter11 weter11 commented Apr 16, 2026

Motivation

  • Manifests can contain stale installdir names (e.g. App <id>) that no longer match the actual folder name, causing incorrect install path resolution and preflight failures.
  • The scan should prefer a verified install directory and recover from stale manifests by probing for app-id markers in installed folders.

Description

  • Update parse_app_manifest_info in src/library.rs to validate the derived steamapps/common/<installdir> before using it as the canonical install path. The validation checks for a matching steam_appid.txt or at least the presence of files in the folder.
  • Add is_valid_install_path, probe_install_dir_by_appid, and rewrite_manifest_installdir helpers to src/library.rs to perform the validation, probe steamapps/common/*/steam_appid.txt for the app ID, and optionally rewrite the manifest installdir when a different folder name is recovered.
  • Fall back to probing steamapps/common/*/steam_appid.txt when the manifest-derived path is invalid, and use the recovered folder as the canonical install path (mirrors SteamClient::probe_install_dir_by_appid strategy in src/steam_client.rs).
  • Add regression test tests/library_scan_fallback.rs which simulates a manifest with installdir = "App 2410180" while the actual folder is Portal Prelude RTX containing steam_appid.txt = 2410180, asserting the scan resolves to the real folder and that the manifest is rewritten.

Testing

  • Ran code formatting with cargo fmt --all which completed successfully.
  • Ran the targeted tests with cargo test --test library_scan_fallback --test path_resolution and both tests completed successfully (all ran and passed).

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant