fix: keep VIctory persistent data outside the cache #322

Open
github-bot wants to merge 1 commit from github-bot/gh-322 into main AGit
Owner

@⁠mauroalvare on GitHub · 2026-11-26 03:00 UTC · original
mauroalvare:codex/victory-data-outside-cache → main · +100 −3 · 5 files · 1 commits · open

Change

Through the launcher, -Override can set VICTORY_DATA_DIR at or below the cache directory selected by victory.toml. Neptune then creates the title's persistent storage inside a directory intended for disposable caches. Clearing the cache can remove saves as well.

Validate the paths in Config::load after applying TOML and environment precedence. Resolve existing ancestors and compare path components, including case aliases on Windows. The diagnostic names the two paths and the setting that can move the data directory outside the cache.

This ports dereoalex's change and adds native Windows verification through the AnyXboxX launcher. The source and coauthor are recorded in the commit and THIRD_PARTY.md. Marvisak/VIctory #1789

Verification

Base c4c93bdc413191a9dc909998d2d53080a3f0c880, head 824ca09. Windows PowerShell 5.1, Rust 1.98.1 MSVC and Python 3.13.15.

Synthetic configuration Base Port
TOML cache CachÉ, override data caché\saves, with -Warm Exit 0, title storage inside the cache Exit 1 before either directory is created
Same path for cache and data, without -Warm Exit 0, title storage inside the cache Exit 1 before either directory is created
Sibling paths cache and cache-saves, with -Warm Exit 0, separate directories Exit 0, separate directories
# From third_party/victory
cargo test --locked -p victory-core persistent_data_cannot
Base with the regression tests: 2 failed, 12 filtered out

cargo test --locked -p victory-core
14 passed, 0 ignored, including the Windows Unicode case-alias test

cargo build --locked -p victory
Succeeded on base and port

rustfmt --edition 2024 --check crates/victory-core/src/config.rs crates/victory-core/src/policy.rs
Passed

cargo clippy --locked -p victory-core --all-targets -- -D warnings
Passed

cargo test --locked -p victory-loader --test load_probe
2 passed

cargo xtask policy
asset policy: 199 files ok

# From the AnyXboxX root
python -m pytest tests/test_lanceur_victory.py -q -rs
25 passed

python -m pytest -rs
1665 passed, 0 skipped

python -m ruff check --select W605,F,E9 PrototypeScarlett tests tools
All checks passed!

The full pytest suite ran on the RTX 5070 Ti with driver 621.40 and also ran its explicit WARP cases. C++ runtime, Rust bridge and TomBox binaries were reused from identical source trees and submodule commit.

Oracle and test data

The end-to-end smoke used the real PowerShell launcher, a prebuilt Neptune CLI from cargo build --locked -p victory, and a temporary Cargo stub that reused that binary. A synthetic title from tests/pe_builder.py returns zero. A temporary TOML file supplies the cache and a safe default data path. -Override sets VICTORY_CONFIG and replaces VICTORY_DATA_DIR for each case. The smoke checks exit status and whether the cache and title storage directories exist before cleanup.

  • One behavior with regression tests that fail on the base.
  • Synthetic inputs throughout.
  • Source attribution, lint, README consistency and the asset policy checked.

Investigation, porting and verification were assisted by OpenAI Codex.

**@⁠mauroalvare** on GitHub · 2026-11-26 03:00 UTC · [original](https://github.com/LooperSalty/AnyXboxX/pull/322) `mauroalvare:codex/victory-data-outside-cache` → `main` · +100 −3 · 5 files · 1 commits · open ## Change Through the launcher, `-Override` can set `VICTORY_DATA_DIR` at or below the cache directory selected by `victory.toml`. Neptune then creates the title's persistent storage inside a directory intended for disposable caches. Clearing the cache can remove saves as well. Validate the paths in `Config::load` after applying TOML and environment precedence. Resolve existing ancestors and compare path components, including case aliases on Windows. The diagnostic names the two paths and the setting that can move the data directory outside the cache. This ports dereoalex's change and adds native Windows verification through the AnyXboxX launcher. The source and coauthor are recorded in the commit and `THIRD_PARTY.md`. [Marvisak/VIctory #1789](https://github.com/Marvisak/VIctory/pull/1789) ## Verification Base `c4c93bdc413191a9dc909998d2d53080a3f0c880`, head `824ca09`. Windows PowerShell 5.1, Rust 1.98.1 MSVC and Python 3.13.15. | Synthetic configuration | Base | Port | | --- | --- | --- | | TOML cache `CachÉ`, override data `caché\saves`, with `-Warm` | Exit 0, title storage inside the cache | Exit 1 before either directory is created | | Same path for cache and data, without `-Warm` | Exit 0, title storage inside the cache | Exit 1 before either directory is created | | Sibling paths `cache` and `cache-saves`, with `-Warm` | Exit 0, separate directories | Exit 0, separate directories | ```text # From third_party/victory cargo test --locked -p victory-core persistent_data_cannot Base with the regression tests: 2 failed, 12 filtered out cargo test --locked -p victory-core 14 passed, 0 ignored, including the Windows Unicode case-alias test cargo build --locked -p victory Succeeded on base and port rustfmt --edition 2024 --check crates/victory-core/src/config.rs crates/victory-core/src/policy.rs Passed cargo clippy --locked -p victory-core --all-targets -- -D warnings Passed cargo test --locked -p victory-loader --test load_probe 2 passed cargo xtask policy asset policy: 199 files ok # From the AnyXboxX root python -m pytest tests/test_lanceur_victory.py -q -rs 25 passed python -m pytest -rs 1665 passed, 0 skipped python -m ruff check --select W605,F,E9 PrototypeScarlett tests tools All checks passed! ``` The full pytest suite ran on the RTX 5070 Ti with driver 621.40 and also ran its explicit WARP cases. C++ runtime, Rust bridge and TomBox binaries were reused from identical source trees and submodule commit. ## Oracle and test data The end-to-end smoke used the real PowerShell launcher, a prebuilt Neptune CLI from `cargo build --locked -p victory`, and a temporary Cargo stub that reused that binary. A synthetic title from `tests/pe_builder.py` returns zero. A temporary TOML file supplies the cache and a safe default data path. `-Override` sets `VICTORY_CONFIG` and replaces `VICTORY_DATA_DIR` for each case. The smoke checks exit status and whether the cache and title storage directories exist before cleanup. - [x] One behavior with regression tests that fail on the base. - [x] Synthetic inputs throughout. - [x] Source attribution, lint, README consistency and the asset policy checked. Investigation, porting and verification were assisted by OpenAI Codex.
Port the effective-path check and Windows case-alias regression to the Neptune base.

Source: https://github.com/Marvisak/VIctory #1789
Co-authored-by: dereoalex <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:43:01 +00:00
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/322/head:github-bot/gh-322'
git switch 'github-bot/gh-322'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-322'
git switch 'github-bot/gh-322'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-322'
git switch 'github-bot/gh-322'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-322'
git switch 'main'
git merge --squash 'github-bot/gh-322'
git switch 'main'
git merge --ff-only 'github-bot/gh-322'
git switch 'main'
git merge 'github-bot/gh-322'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.