Repository navigation
Conversation
mercuryVM
left a comment
There was a problem hiding this comment.
Tested 5f21114 on Windows 11, RTX 5070, MSVC: the workspace passes (196 outside victory-shader), including tests/shader_paths.rs.
- Safety screen: the
Cargo.tomlandCargo.lockchanges only addtempfileas a dev-dependency ofapps/victory. It is already a workspace dependency used by other crates' tests, so the lockfile only gains the edge and no new package. - Reporting traversal errors, keeping the scan going, and then failing with "scan incomplete" after the summary is the right behaviour for batch scripts. Suppressing the "none found" hint when the emptiness came from errors avoids a misleading message.
scan_entriesis shared by both commands. #115 does the same forcensus, with a depth-0 hard error instead. The two are slightly inconsistent (fail fast versus finish then fail), which is worth aligning eventually, but not in this PR.
No issues found.
AI-assisted (Claude Code).
…ry scans Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
catminou4
left a comment
There was a problem hiding this comment.
Triage: this and #534 attack the same problem (shader/translate scan input failures) with different designs. Comparison for whoever reviews:
- #517 (this one): shared
scan_entrieshelper counting walk errors, hard failure at the end (anyhow::ensure!(walk_errors == 0)), missing root surfaces as a traversal error, integration test drives the realvictorybinary (tests/shader_paths.rs, exit code 1, stderr names both bad inputs), and Cargo.lock is updated. - #534: per-file errors collected and printed but the command still exits 0; missing root is a hard
anyhow::ensure!; unit tests in shader.rs/translate.rs; Cargo.lock NOT updated → breaks--lockedbuilds (verified locally, see my review there).
Semantic difference that matters: #517 fails the entire scan if any traversal error occurs anywhere in the tree (one unreadable file in a big dump kills the run); #534 only fails on a missing root and merely reports per-file errors. For a diagnostic CLI over multi-GB title dumps I'd mildly prefer #534's distinction, but #517's integration test and lockfile are stronger as submitted.
Not verifiable on macOS (app crate doesn't build here); both diffs read correctly statically.
|
Independent review on Windows 11 x64 / MSVC (merged PR head 5f21114 into current main; reviewed the full origin/main..HEAD diff, clean auto-merge on translate.rs). Verified:
Looks correct and well scoped. scan_entries now counts (and prints) every WalkDir error; both shader-info and translate emit a non-zero exit via anyhow::ensure! when any traversal error occurred, while still printing the partial results first (best-effort output + honest exit code). Suppressing the "(none found...)" hint on an incomplete scan avoids reporting a failed scan as empty. The new test is hermetic/synthetic - it clears VICTORY_PAIRS so no GPU/D3D12 is needed - and checks exit 1, both missing roots, the exact count (2), and that the valid file is still scanned. Non-blocking observations:
No blocking issues - nice, focused fix. AI-assisted; synthetic tests only, no game files. |
|
Thanks @geiyiliyabumo. Added the clean-directory case in bab15db. Both To reproduce, run For the overlap discussion, #115 covers census. At AI-assisted. All fixtures for this test are synthetic. |
Where a fork-only change duplicates upstream's own version of a feature, upstream's is kept and the fork's dropped: - victory-shader is upstream's crate with the fork-only merges replayed onto it oldest first; those that do not apply onto upstream are dropped (37 of 63: among them Marvisak#704/raw views, gather4_l, the lane-mask and Marvisak#308 ports, Marvisak#947, Marvisak#1022, Marvisak#1112, Marvisak#1090, Marvisak#1182). Marvisak#284 (legacy fused madds) and Marvisak#98 (permlane16 in whole-wave sections) are dropped too: the first disagrees with upstream's hardware-checked model, the second refused 46 programs upstream translates. - translate: upstream's --cache replaces Marvisak#254's write-cache and work queue; Marvisak#378, Marvisak#517, Marvisak#673 and the victory.toml console are re-applied. - victory-gpu: upstream's stride table, page table and heap views replace the fork's Marvisak#704/stride-table wiring; fork-only fixes re-applied on top. Package (shaders.rpf, translate --validate --list, counts): vertex/pixel emitted 12559 -> 14295 of 14337, compute 2359 -> 2628 validated, mesh 2730 -> 2811 validated. Tests: the failures left (rect fourth corner, two stride tests, row order, gather4 at a level, memory table, dynamic heap slots) fail on upstream main as well on this host. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Automated triage for the maintainers. Needs rebase. This PR does not merge cleanly into current The content has not been reviewed yet; it will be once the branch is rebased onto Generated by Claude Code |
|
Resolved the conflicts in On Windows/MSVC, AI-assisted; the scan regression uses a synthetic fixture. |
Both
shader-infoandtranslateexit 0 when a scan root is missing. This makes an incomplete batch look like a successful scan of an empty directory.Report each traversal error on stderr, keep scanning accessible inputs, and exit 1 after printing the partial summary. A readable empty directory still exits 0. Scripts that use the exit status can now detect partial results.
Reproduce with
cargo run -p victory -- shader-info missing-dirorcargo run -p victory -- translate missing-dir, using a path that does not exist. On Windows 11 with Rust 1.98.1, both returned 0 ond2a4baeand 1 with this patch.cargo test --locked -p victory --test shader_pathschecks that both commands count a synthetic container between two missing roots and report both paths. The workspace suite passed (265 passed, 4 ignored).#254 moves the traversal loop in
translate; combining the changes requires resolving that hunk. #115 coverscensus.Codex implemented and tested the change. Claude Code independently reviewed the final diff.