Skip to content

fix(xtask): restore make lint to green on main - #50

Merged
nerdalert merged 1 commit into
praxis-proxy:mainfrom
jordigilh:fix/image-overrides-match-same-arms
Aug 13, 2026
Merged

fix(xtask): restore make lint to green on main#50
nerdalert merged 1 commit into
praxis-proxy:mainfrom
jordigilh:fix/image-overrides-match-same-arms

Conversation

@jordigilh

Copy link
Copy Markdown
Contributor

Context

Noticed while investigating ai#716 that main's own lint CI check has been red since ad9f36c (everything else — tests, coverage, msrv, etc. — is green).

What's wrong

make lint fails on two independent issues in the same gate, both pre-existing:

  1. cargo clippy -D warnings (clippy::match_same_arms)IngressMode::Global and IngressMode::Workload both map to the same DEFAULT_WORKLOAD_IMAGE_PULL_POLICY value in demo_image_pull_policy. Merged into a single or-pattern arm (clippy's own suggested fix), with a doc comment on why the parameter stays despite both variants currently sharing a default. Existing test coverage (public_demo_modes_use_registry_defaults) already asserts both variants return the same value.
  2. cargo +nightly-2026-03-28 fmt --all -- --check (same nightly this repo's CI pins) — two call sites had drifted from the formatter's output. CI's lint job short-circuits at the clippy step today, so this second failure is currently hidden: fixing only the clippy issue would just move the same red check to a different error. Ran the pinned formatter to resolve — purely whitespace/line-wrapping, no logic changes.

Test plan

  • cargo clippy --workspace --all-targets -- -D warnings — clean
  • cargo +nightly-2026-03-28 fmt --all -- --check — clean
  • cargo test -p xtask image_overrides — 6/6 passing
  • cargo machete — clean

`make lint` fails on main today with two independent issues in the
same gate, both pre-existing and unrelated to any change of mine:

1. `cargo clippy -D warnings` (clippy::match_same_arms): both
   `IngressMode::Global` and `IngressMode::Workload` map to the same
   `DEFAULT_WORKLOAD_IMAGE_PULL_POLICY` value in
   `demo_image_pull_policy`. Merged into a single or-pattern arm,
   matching clippy's own suggested fix, with a doc comment explaining
   why the parameter is kept despite both variants currently sharing a
   default. Existing test coverage
   (`public_demo_modes_use_registry_defaults`) already asserts both
   variants return the same value, so no new test is needed.

2. `cargo +nightly-2026-03-28 fmt --all -- --check`: two call sites
   (`combined_site_demo.rs`, `image_overrides.rs`'s own test module)
   had drifted from the pinned nightly formatter's output. CI's own
   `lint` job short-circuits at the clippy step today, so this second,
   independent failure is currently hidden — fixing only the clippy
   issue would just move the same red `lint` check to a different
   error. Ran `cargo +nightly-2026-03-28 fmt --all` (the exact
   toolchain CI pins) to resolve; purely whitespace/line-wrapping, no
   logic changes.

Signed-off-by: Jordi Gil <jgil@redhat.com>

@nerdalert nerdalert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@nerdalert
nerdalert merged commit 1271ac3 into praxis-proxy:main Aug 13, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants