HLE: reject saves whose committed container lacks a manifest #570
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/570"
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?
Imported from Marvisak/VIctory. Originally posted by Quat3rnion on 2026-11-24T05:04:39Z.
What
current()reported a missing manifest withNotFound, the same error as acontainer that does not exist. An update then treated that as a fresh
container, committed a new v1 and returned
S_OK, while readers still chosethe malformed newest version and the main flow deleted the new v1. A version
directory that exists must have a readable manifest; anything else is now
InvalidData, which both readers and submit map toNO_ACCESS.An AI tool wrote part of this change.
Tested
cargo test --workspace: 165 passed, 0 failed, 3 ignored. A tempdir regression commits two versions, removes the newest manifest, submits an update and checksNO_ACCESSwith no third version created.cargo check --target x86_64-pc-windows-gnu --workspace --testspasses. No Windows host here.cargo xtask policypasses (150 files ok). No game files or data from them were added.Checklist
cargo xtask policypasses. No game files or data from them were added.Imported from Marvisak/VIctory. Originally posted by mercuryVM on 2026-11-24T08:26:50Z.
Review: APPROVED
Tested
edbd1a7on Windows 11, RTX 5070, MSVC:cargo test --workspace --no-fail-fastpasses (265 passed, 0 failed), includinga_committed_container_without_its_manifest_is_rejected.The distinction is the right one.
NotFoundmust mean "no container", but a version directory without its manifest is a damaged commit. Mapping every manifest read failure toInvalidDatamakesupdatereturnNO_ACCESSinstead of quietly starting a new v1 over a damaged save that readers would still pick. The test checks that no new version directory appears.No issues found.
AI-assisted (Claude Code).
Imported from Marvisak/VIctory. Originally posted by geiyiliyabumo on 2026-11-24T12:22:34Z.
Independent verification & code review on Windows 11 x64 MSVC (merged onto
mainffe310e):Checks Run
cargo xtask policy: PASS (154 files ok)cargo clippy -p victory-hle --all-targets --locked -- -D warnings(default +--features diagnostics): PASS (0 warnings)cargo test -p victory-hle --locked -- xgamesave: PASS (8/8tests, includinga_committed_container_without_its_manifest_is_rejected)Review
Looks clean and ready to merge — once a committed
v<n>directory exists, failing to read itsmanifestnow producesInvalidDatainstead of propagatingNotFoundintocurrent_named, preventing updates from treating a corrupted container as empty and committing a strayv1.AI-assisted; synthetic tests only, no game files.
Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T00:25:12Z.
Automated triage for the maintainers. Closing because another open pull request covers the same change.
See #1729. A version folder without a manifest is refused instead of being taken for a missing container; #1729 changes the same lines and fixes more (falls back to the newest readable version, never prunes below an unreadable one).
If this is mistaken, reply here with what was missed (or push a change and say so) and it will be looked at again. Thank you for the contribution.
Pull request closed