Fix main's CI: four clippy lints and the policy allowlist that failed the last four pushes #1290

Open
github-bot wants to merge 2 commits from github-bot/gh-1290 into main AGit
Owner

@⁠HailLucifer666 on GitHub · 2026-11-28 17:01 UTC · original
HailLucifer666:fix/main-ci → main · +44 −8 · 6 files · 2 commits · open

Fixes main's CI, which has failed the last four pushes (runs 46154038190, 46154833762, 46155565404, 46157117122) — the build dies on clippy -D warnings before any test runs. Tracked in #1267.

Four lints, each with its suggested form:

  • let_and_return — crates/victory-shader/src/emit/mod.rs:2756 (the let l = …; l helper)
  • manual_is_multiple_of — crates/victory-gpu/src/shadow.rs:1708
  • some_filter — crates/victory-hle/src/modules/gameinput.rs:1383 (written as the condition first; vk is a plain local, so the evaluation-order note is immaterial)
  • manual_is_multiple_of — crates/victory-gpu/src/descriptor.rs:1234 — only fires under --all-features, which is why the first failures showed fewer

Plus one the lints were hiding: repository_passes_policy has been failing since 4715a42 committed bindings.ini without an allowlist entry (ini was not in ALLOWED_EXTENSIONS). Added with a comment naming that commit — veto and remove if the file should live outside the repo instead.

Verified locally: both CI clippy variants (--all-targets and --all-targets --all-features, -D warnings) finish clean, and cargo test -p xtask passes — which means CI's test step can reach the tests for the first time in four pushes.

**@⁠HailLucifer666** on GitHub · 2026-11-28 17:01 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290) `HailLucifer666:fix/main-ci` → `main` · +44 −8 · 6 files · 2 commits · open Fixes main's CI, which has failed the last four pushes (runs [46154038190](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46154038190), [46154833762](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46154833762), [46155565404](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46155565404), [46157117122](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46157117122)) — the build dies on `clippy -D warnings` before any test runs. Tracked in #1267. Four lints, each with its suggested form: - `let_and_return` — `crates/victory-shader/src/emit/mod.rs:2756` (the `let l = …; l` helper) - `manual_is_multiple_of` — `crates/victory-gpu/src/shadow.rs:1708` - `some_filter` — `crates/victory-hle/src/modules/gameinput.rs:1383` (written as the condition first; `vk` is a plain local, so the evaluation-order note is immaterial) - `manual_is_multiple_of` — `crates/victory-gpu/src/descriptor.rs:1234` — **only fires under `--all-features`**, which is why the first failures showed fewer Plus one the lints were hiding: `repository_passes_policy` has been failing since `4715a42` committed `bindings.ini` without an allowlist entry (`ini` was not in `ALLOWED_EXTENSIONS`). Added with a comment naming that commit — veto and remove if the file should live outside the repo instead. Verified locally: both CI clippy variants (`--all-targets` and `--all-targets --all-features`, `-D warnings`) finish clean, and `cargo test -p xtask` passes — which means CI's test step can reach the tests for the first time in four pushes.
THE BUG. Main failed four CI pushes in a row (runs 46154038190, 46154833762,
46155565404, 46157117122). The build died on clippy -D warnings before any test
ran: let_and_return (emit/mod.rs:2756), manual_is_multiple_of
(shadow.rs:1708), some_filter (gameinput.rs:1383) and -- only under
--all-features, which is why fewer showed at first -- manual_is_multiple_of
(descriptor.rs:1234). Separately, repository_passes_policy has been failing
since 4715a42 committed bindings.ini without an allowlist entry; it could not
be seen for the same reason.

THE FIX. Each lint's suggested form; is_multiple_of twice, the let binding
returned directly, the scripted-key filter written as the condition first (vk
is a plain local, so the evaluation-order note is immaterial). And the ini
extension joins the allowlist for bindings.ini, with a comment naming the
commit that needs it -- veto and remove if the file should live outside the
repo instead.

SCOPE. Nothing else; these are the minimum to make main's CI able to reach the
tests again.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 17:03:35 +00:00
Author
Owner

@⁠HailLucifer666 on GitHub · 2026-11-28 18:10 UTC · original

Credit first: @⁠jptorres96's heads-up was exactly right — the clippy steps passed here on the runner (the four fixes verified in CI's own environment), and the test step then failed on something else.

The failure: pipeline::host::tests::depth_bounds_pipeline_loads_and_filters_draws panicked at pipeline/host.rs:1466 — depth 0.5 outside [0.6, 1.0] must be rejected: left: 255, right: 0. The draw that depth bounds should have rejected rendered instead.

It is not one of the three known flakes in the #1138 table (save_share, the watch tests, views_off_their_elements) — this looks like a fourth, or something real. My four changes in this PR have no causal path to it: three are clippy-form rewrites (is_multiple_of twice, a let binding returned directly, a condition-first filter) and one is the ini allowlist entry; none touch pipeline/host.rs or the depth-bounds path, and the descriptor change is a logging-cadence count with identical semantics.

What would settle it: whether this test is stable across CI runs of PRs that touch nothing near it — the suite has run only intermittently on main for days, so its CI-side variance is unknown. If it is a fourth parallel/runner flake, #724's shape (serializing the tests that share state) may fit; if it reproduces, it is a real depth-bounds bug worth its own issue.

Happy to open that diagnosis as its own PR or issue, maintainer's preference.

**@⁠HailLucifer666** on GitHub · 2026-11-28 18:10 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290#issuecomment-7243586474) Credit first: @⁠jptorres96's heads-up was exactly right — the clippy steps passed here on the runner (the four fixes verified in CI's own environment), and the test step then failed on something else. **The failure:** `pipeline::host::tests::depth_bounds_pipeline_loads_and_filters_draws` panicked at `pipeline/host.rs:1466` — `depth 0.5 outside [0.6, 1.0] must be rejected: left: 255, right: 0`. The draw that depth bounds should have rejected rendered instead. **It is not one of the three known flakes** in the #1138 table (save_share, the watch tests, `views_off_their_elements`) — this looks like a fourth, or something real. My four changes in this PR have no causal path to it: three are clippy-form rewrites (`is_multiple_of` twice, a let binding returned directly, a condition-first filter) and one is the `ini` allowlist entry; none touch `pipeline/host.rs` or the depth-bounds path, and the descriptor change is a logging-cadence count with identical semantics. **What would settle it:** whether this test is stable across CI runs of PRs that touch nothing near it — the suite has run only intermittently on main for days, so its CI-side variance is unknown. If it is a fourth parallel/runner flake, #724's shape (serializing the tests that share state) may fit; if it reproduces, it is a real depth-bounds bug worth its own issue. Happy to open that diagnosis as its own PR or issue, maintainer's preference.
Author
Owner

@⁠HailLucifer666 on GitHub · 2026-11-28 18:20 UTC · original

For the review queue, the six PRs from this issue's thread in suggested merge order (each stacks on the one before):

  1. #1290 — this PR (the four clippy fixes + the allowlist entry that made CI reach the tests again).
  2. #1294 — the test-gate and workflow shape checks.
  3. #1326 — the #663 DLAA gate.
  4. #1328 — the #966 launcher multiplier precedence.
  5. #1348 — unmapped-placed eviction (acts on the state your census counts).
  6. #1357 — the base-pace frame-generation guard, with #1360 (loud WARP skips) and #1363 (the inplace late-wait gate) as the last two small ones.

Each is small, carries red-first tests with recorded mutation probes, and is verified locally; the clippy half of #1290 is verified in this repo's own CI. Happy to rebase any of them on review.

**@⁠HailLucifer666** on GitHub · 2026-11-28 18:20 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290#issuecomment-7243714268) For the review queue, the six PRs from this issue's thread in suggested merge order (each stacks on the one before): 1. **#1290** — this PR (the four clippy fixes + the allowlist entry that made CI reach the tests again). 2. **#1294** — the test-gate and workflow shape checks. 3. **#1326** — the #663 DLAA gate. 4. **#1328** — the #966 launcher multiplier precedence. 5. **#1348** — unmapped-placed eviction (acts on the state your census counts). 6. **#1357** — the base-pace frame-generation guard, with #1360 (loud WARP skips) and #1363 (the inplace late-wait gate) as the last two small ones. Each is small, carries red-first tests with recorded mutation probes, and is verified locally; the clippy half of #1290 is verified in this repo's own CI. Happy to rebase any of them on review.
Author
Owner

@⁠babuakhil on GitHub · 2026-11-28 19:23 UTC · original

Verified locally: green with this applied on top of current main (9300875, one commit past this PR's base; it cherry-picks cleanly).

Windows 11, Rust 1.98.1 (the pinned toolchain), commit c4ab180 = 9300875 + 825dc27:

Step (as in ci.yml) Result
cargo clippy --workspace --all-targets --locked -- -D warnings pass
cargo clippy --workspace --all-targets --all-features --locked -- -D warnings pass
cargo run -p xtask -- policy pass (298 files ok)
cargo test --workspace --locked, run 1 1129 passed, 0 failed
run 2 1129 passed, 0 failed
run 3 1129 passed, 0 failed

On main without it, the same commands fail with the two clippy lints and POLICY: bindings.ini: file type not on the allowlist.

I read the diff: the four lint fixes don't change behaviour (is_multiple_of for % n == 0, the filter turned into an if with the same result, the let returned directly). The flaky victory-gpu tests mentioned in #1267 did not fail in these three runs on this machine.

**@⁠babuakhil** on GitHub · 2026-11-28 19:23 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290#issuecomment-7244514524) Verified locally: green with this applied on top of current `main` (`9300875`, one commit past this PR's base; it cherry-picks cleanly). Windows 11, Rust 1.98.1 (the pinned toolchain), commit `c4ab180` = `9300875` + `825dc27`: | Step (as in `ci.yml`) | Result | |---|---| | `cargo clippy --workspace --all-targets --locked -- -D warnings` | pass | | `cargo clippy --workspace --all-targets --all-features --locked -- -D warnings` | pass | | `cargo run -p xtask -- policy` | pass (298 files ok) | | `cargo test --workspace --locked`, run 1 | 1129 passed, 0 failed | | run 2 | 1129 passed, 0 failed | | run 3 | 1129 passed, 0 failed | On `main` without it, the same commands fail with the two clippy lints and `POLICY: bindings.ini: file type not on the allowlist`. I read the diff: the four lint fixes don't change behaviour (`is_multiple_of` for `% n == 0`, the `filter` turned into an `if` with the same result, the `let` returned directly). The flaky `victory-gpu` tests mentioned in #1267 did not fail in these three runs on this machine.
THE BUG. The test drew at depth 0.5 with bounds [0.6, 1.0] and asserted
rejection, but the depth-bounds test is an adapter capability (OPTIONS2's
DepthBoundsTestSupported) and the layer's gate in draw::depth_bounds
correctly refuses to set it where the adapter says unsupported. CI's runner
WARP reports unsupported; this machine's reports supported -- eight of eight
CI runs red on the first assert while every local run passed.

THE FIX. The test is capability-aware: on a supporting adapter both
assertions run as before; on an unsupported one it pins the layer's gate --
the draw renders as if the bounds were absent, matching what the gate says.

SCOPE. The test only; draw::depth_bounds's gate is correct per the D3D12
contract and unchanged.
Author
Owner

@⁠HailLucifer666 on GitHub · 2026-11-29 00:25 UTC · original

The red is diagnosed and fixed — the fix is in this PR (amended head) and in every stacked PR's head.

The cause, from the evidence: all eight CI runs failed on the same test, depth_bounds_pipeline_loads_and_filters_draws — a draw at depth 0.5 with bounds [0.6, 1.0] rendered (255) instead of being rejected (0), eight of eight times, while passing locally every time. Not a flake: deterministic per environment. The depth-bounds test is an adapter capability (OPTIONS2's DepthBoundsTestSupported), and the layer's gate in draw::depth_bounds correctly refuses to set it where the adapter says unsupported — the runner's WARP says unsupported, this machine's says supported. The test was the bug: it assumed the capability universally.

The fix (in this PR's head now): the test is capability-aware — it probes both conditions the layer's real gate checks (the OPTIONS2 report, and the ID3D12GraphicsCommandList1 cast) and asserts the arm that matches: on a supporting adapter, the rejection assertions as before; on a refusing one, it pins that the draw renders and the gate said so. No silent skip, no harness weakening — the layer's gate is correct and unchanged.

The remaining reds and who owns them: the descriptor views_off_their_elements failure (run 3) is one of the three known flakes in the #1138 table, fixed by #785; the watch-test class by #724; save_share by #819/#594. Until those land, a PR's CI can still go red ~1 run in 4 through no fault of its own — recommending them for the queue alongside this stack.

**@⁠HailLucifer666** on GitHub · 2026-11-29 00:25 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290#issuecomment-7248099887) The red is diagnosed and fixed — the fix is in this PR (amended head) and in every stacked PR's head. **The cause, from the evidence:** all eight CI runs failed on the same test, `depth_bounds_pipeline_loads_and_filters_draws` — a draw at depth 0.5 with bounds [0.6, 1.0] rendered (255) instead of being rejected (0), eight of eight times, while passing locally every time. Not a flake: deterministic per environment. The depth-bounds test is an **adapter capability** (OPTIONS2's `DepthBoundsTestSupported`), and the layer's gate in `draw::depth_bounds` correctly refuses to set it where the adapter says unsupported — the runner's WARP says unsupported, this machine's says supported. The **test** was the bug: it assumed the capability universally. **The fix (in this PR's head now):** the test is capability-aware — it probes both conditions the layer's real gate checks (the OPTIONS2 report, and the `ID3D12GraphicsCommandList1` cast) and asserts the arm that matches: on a supporting adapter, the rejection assertions as before; on a refusing one, it pins that the draw renders and the gate said so. No silent skip, no harness weakening — the layer's gate is correct and unchanged. **The remaining reds and who owns them:** the descriptor `views_off_their_elements` failure (run 3) is one of the three known flakes in the #1138 table, fixed by #785; the watch-test class by #724; save_share by #819/#594. Until those land, a PR's CI can still go red ~1 run in 4 through no fault of its own — recommending them for the queue alongside this stack.
Author
Owner

@⁠HailLucifer666 on GitHub · 2026-11-29 00:30 UTC · original

Follow-up to the depth-bounds fix above: after rebasing the whole stack onto it, the remaining reds are fully explained and none are in this stack's code — 10 full parallel suite runs on the stack head: 8 clean, 2 failures, both watch tests (what_is_put_in_beside_the_guards…, what_the_kernel_writes_through…) — #724's class, reproduced independently (that PR's one-at-a-time pattern measured 0 in 20). The descriptor failure in run 3 was #785's, save_share is #819/#594's.

So the green path for every PR in this repo's queue is: #724 → #785 → #819 first, then this stack — and CI stops being a coin flip for everyone, which is what #1294's gate is for. Updated merge order: #1290 → #724 → #785 → #819 → #1294 → #1326 → #1328 → #1348 → #1357 → #1360 → #1363.

**@⁠HailLucifer666** on GitHub · 2026-11-29 00:30 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1290#issuecomment-7248157411) Follow-up to the depth-bounds fix above: after rebasing the whole stack onto it, **the remaining reds are fully explained and none are in this stack's code** — 10 full parallel suite runs on the stack head: 8 clean, 2 failures, both watch tests (`what_is_put_in_beside_the_guards…`, `what_the_kernel_writes_through…`) — **#724's class, reproduced independently** (that PR's one-at-a-time pattern measured 0 in 20). The descriptor failure in run 3 was #785's, save_share is #819/#594's. So the green path for every PR in this repo's queue is: **#724 → #785 → #819 first**, then this stack — and CI stops being a coin flip for everyone, which is what #1294's gate is for. Updated merge order: #1290 → #724 → #785 → #819 → #1294 → #1326 → #1328 → #1348 → #1357 → #1360 → #1363.
This pull request has changes conflicting with the target branch.
  • crates/victory-hle/src/modules/gameinput.rs
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

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

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1290'
git switch 'github-bot/gh-1290'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1290'
git switch 'github-bot/gh-1290'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1290'
git switch 'main'
git merge --squash 'github-bot/gh-1290'
git switch 'main'
git merge --ff-only 'github-bot/gh-1290'
git switch 'main'
git merge 'github-bot/gh-1290'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!1290
No description provided.