HLE: retain unreadable legacy save display metadata (on #2525) #2675
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!2675
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2675"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@jaschinski97-ops on GitHub · 2026-11-25 17:57 UTC · original
jaschinski97-ops:test/windows-legacy-save-retry→main· +139 −14 · 1 files · 6 commits · closed without mergingAn unreadable legacy
.displaycurrently becomes an empty display name during XGameSave migration. Migration can commit that incomplete metadata, retain the locked source folder, then delete the original label on retry. Defer migration when existing display metadata cannot be read; a missing.displaystill means an empty name.Stacked on #2525, with its original commit/author retained. Land that PR first. The additional production change is only the display-file error handling. Existing partially migrated destinations are not repaired by this follow-up.
Tests hold either a legacy blob or
.displaywith Windows FILE_SHARE_NONE, confirm ERROR_SHARING_VIOLATION32, require no partial v1, then unlock and verify both exact decoded blob names/payloads and the display before source removal. A genuinely missing metadata file remains accepted.Validation:
Claims NEW-215 and NEW-216; completion.
AI-assisted with Codex: separate implementation and coordinator/agent reviews. Synthetic files only; no GPU/game data or gameplay claim.
@oni-swr on GitHub · 2026-11-25 18:34 UTC · original
Independent verification (review, not a task claim) — covered by the existing claim on #1633.
b29c3a7510f55c06f30ea17e038d6fc2a6b564c4(OPEN, non-draft, merges cleanly; merge-base ==origin/main)origin/main:13f91caee25f2fdf2c062be5f7a27f058e51cbcaVICTORY_WARP=1,VICTORY_D3D12_WARP=1,dxil.dll1.8.2502.11 (Windows Kit 10.0.26100.0 x64), no physical GPU used (the HLE tests do not open a GPU), no game files, synthetic temp files only.a805860, which is still open at that head) plus 3 follow-up commits, so the diff againstmaincontains #2525's production changes (version overflow, blob validation) as well as the display-metadata fix.Commands and results
cargo test --locked -p victory-hle --lib xgamesave→ 15 passed, 0 failed, 0 ignored. This includes the newa_locked_legacy_blob_delays_migration_until_it_can_be_read,a_locked_legacy_display_delays_migration_until_it_can_be_read,missing_legacy_display_metadata_can_still_migrateandstray_u64_max_version_does_not_lose_the_save.cargo test --locked -p victory-hle(full crate) → lib 150 passed, 0 failed, 0 ignored;tests/fidelityfx.rs1 passed;tests/no_dll_planting.rs1 passed; doc-tests 0 tests. No failures; I did not hit thedstorageflake mentioned in the description.cargo clippy --locked -p victory-hle --all-targets→ clean, no warnings.Negative controls (each production hunk reverted on its own on the PR head, then restored;
cargo test --locked -p victory-hle --lib xgamesave, each run 14 passed, 1 failed).displayread as empty (unwrap_or_default) →a_locked_legacy_display_delays_migration_until_it_can_be_readFAILED.a_locked_legacy_blob_delays_migration_until_it_can_be_readFAILED.checked_add→stray_u64_max_version_does_not_lose_the_saveFAILED (left == rightassertion).loadremoved) →an_unreadable_newer_version_does_not_cost_the_saveFAILED (the new "missing blob" case).missing_legacy_display_metadata_can_still_migratepasses on the PR head. Because it does not need the fix, it is not expected to fail onmain.Review notes
NotFoundstill means an empty name, and any other read error returnsNoneso the whole migration is deferred and the legacy folder is kept. The blob loop now propagates the read error with?instead of dropping the entry infilter_map, which closes the partial-publish case.share_mode(0), explicitly assertsERROR_SHARING_VIOLATION(32), checks that nov1is published, and checks the retry result and removal of the old folder. They arecfg(windows), so they do not run on other platforms.NotFounderror on.display, including a permanent one such as a permissions problem, now blocks migration indefinitely, since every later open retries and defers again. That looks intended, because the data stays safe, but it is worth knowing.AI disclosure: independent verification by Claude Code (Claude Sonnet 5.5).
@kotekompotek on GitHub · 2026-11-25 18:35 UTC · original
Correct layering on #2525. Deferring on an unreadable .display closes the lose-the-name retry window, and load() now rejecting a version whose manifest names a missing blob prevents publishing a version that points at data that isn't there. The checked_add(1) on the version number is a good catch too. Needs #2525 first, as stated.
@fuzeofficlal on GitHub · 2026-11-25 19:09 UTC · original
Independent Windows 11 verification and code review of
b29c3a75(on13f91ca):Verification (
rustc 1.98.1MSVC)cargo clippy --locked -p victory-hle --all-targets -- -D warningsand--all-features: 0 warnings.cargo test --locked -p victory-hle: 150 passed, 0 failed (lib, including all new legacy display/blob lock and missing-display tests), plusfidelityfxandno_dll_plantingchecks clean.cargo xtask policy: 184 files ok.Review Notes
NotFound(migrates with empty display name) from transient read errors (returnsNoneand retries once unlocked) works as intended, and the Windows file-lock tests exercise the real locking path.xgamesave.rs:349vsUpdate::submit476-539): if.display(or a blob) is locked whenProvider::openruns somigrate()skipsold, and the title writes a new update to the same container name before the lock clears,Update::submitseescurrent(&self.dir) == Ok(None)and creates a freshv1without the unmigrated legacy blobs. On a subsequentmigrate()after the lock clears,current_named(&dir, name).ok()?.is_some()treats thatv1as a completed prior migration and runsremove_dir_all(old), deleting the unmigrated legacy blobs (inherited from #2525's deferred blob migration and now reachable when.displayis locked too).a805860verbatim,git merge-treeconflicts with #2525 unless merged in order (#2525 first + rebase, or taking #2675 as a superset).@Marvisak on GitHub · 2026-11-25 23:24 UTC · original
Automated triage for the maintainers.
This branch is built on #2525, which was closed today as covered by other PRs, and most of its diff in
crates/victory-hle/src/modules/xgamesave.rsis that PR again: the blob check inloadduplicates the open #1981, and thechecked_addinUpdate::submitduplicates the open #2511. The remaining change, deferringmigratewhen.displayor a blob cannot be read, has the flaw named when #2525 was closed. Once the title saves under that container name,Update::submitcommits a freshv1. The nextProvider::openthen findscurrent_namedset inmigrateand runsremove_dir_all(old), so the legacy data is still lost; a reviewer here describes the same path. A rework against currentmain, without the #1981/#2511 hunks, would need to make a deferred legacy container block or merge into a new save under that name, with a test of that sequence. CI (check) passes.This PR will be closed in 48 hours unless the author pushes a change or a maintainer removes the
triage: proposed closelabel.Generated by Claude Code
63bcca4into legacy-save retry fix a4582bb65c@jaschinski97-ops on GitHub · 2026-11-26 15:41 UTC · original
The refresh CI failed only in unchanged
frame::tests::waits_end_on_ticks_and_count_frames(S_OK0 rather than TIMEOUT1 at frame.rs231); source and failing job are recorded in #3080, which already addresses that timing assumption. All156 native HLE tests and strict Clippy pass. A single new CI attempt is triggered with an explicitly empty commit; product code is unchanged. Rerunning the upstream job directly requires repository admin rights, so I could not use that button/API. I will record the new result rather than treat the first run as green.Pull request closed