Skip to content

fix(eql-mapper): satisfy clippy lints added in Rust 1.100.0 - #515

Merged
tobyhede merged 1 commit into
mainfrom
fix/clippy-1-100-eql-mapper
Nov 23, 2026
Merged

tobyhede merged 1 commit into
mainfrom
fix/clippy-1-100-eql-mapper

Conversation

@tobyhede

Copy link
Copy Markdown
Contributor

Summary

The Lint (Rust stable) CI job installs the latest stable Rust, which is now 1.100.0.
Its clippy rejects two patterns in eql-mapper, the crate that type-checks SQL statements for Proxy, so Lint fails on main and on every open pull request.
This change rewrites both spots the way clippy suggests, with no change in behaviour.

Changes

  • packages/eql-mapper/src/inference/type_error.rs: the UnmappableEncryptedColumn error message passed table twice as a positional format argument, which trips clippy::duplicated_attributes. The message now names the fields inline ({table}, {column}, {column_type}), which thiserror supports. The rendered text is unchanged.
  • packages/eql-mapper/src/transformation_rules/fail_on_placeholder_change.rs: would_edit returned true from an if and then false, which trips clippy::needless_bool. It now returns the condition directly.

Verification

  • Ran CI's lint command with Rust 1.100.0, cargo clippy --locked --all --no-deps --all-targets --all-features -- -D warnings: passed for the whole workspace, so no further 1.100.0 lints were hidden behind these two.
  • Ran cargo fmt --all -- --check with Rust 1.100.0: passed.
  • Ran cargo test -p eql-mapper with the pinned toolchain (1.99.0): 225 passed, 0 failed, 7 ignored.
  • I did not run the integration tests locally; CI runs them.

Related

Unblocks the Lint (Rust stable) check on #512, which fails only because of these two lints.

Review notes

rust-toolchain.toml still pins 1.99.0 for local builds. CI's Lint job uses latest stable, so the two can drift again when the next stable release adds lints. Pinning the Lint job, or bumping the pinned toolchain, is a separate decision.

Acknowledgment

By submitting this pull request, I confirm that CipherStash can use, modify, copy, and redistribute this contribution, under the terms of CipherStash's choice.

The Lint (Rust stable) job installs the latest stable toolchain, which
moved to Rust 1.100.0. Its clippy rejects two patterns in eql-mapper, so
the job now fails on main and on every pull request.

- duplicated_attributes: the UnmappableEncryptedColumn error message
  passed `table` twice as a positional format argument. The message now
  names the variant's fields inline, which thiserror supports, so each
  field appears once. The rendered message is unchanged.
- needless_bool: FailOnPlaceholderChange::would_edit returned `true`
  from an `if` and then `false`. It now returns the condition directly.

Neither change alters behaviour.
@tobyhede
tobyhede marked this pull request as ready for review November 22, 2026 23:45

@cipherstash-agent cipherstash-agent left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review attestation

Reviewed 450d65b · posted from Claude Code (scheduled routine) · claude-opus-5-5 · effort medium
Sources: code-review · claude-opus-5-5; mattpocock-skills:code-review (standards + spec agents) · claude-opus-5-5; review-cross-check · claude-opus-5-5
Skills: code-review, rust-security, mattpocock-skills:code-review, review-cross-check, review-post

No findings.


Generated by Claude Code

@tobyhede
tobyhede requested review from CDThomas and auxesis November 23, 2026 00:26
@tobyhede
tobyhede merged commit f687087 into main Nov 23, 2026
11 checks passed
@tobyhede
tobyhede deleted the fix/clippy-1-100-eql-mapper branch November 23, 2026 02:26
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.

3 participants