Skip to content

style: fix rustfmt and clippy warnings#75

Merged
JP-Ellis merged 1 commit into
mainfrom
chore/fix-fmt-clippy
Jun 22, 2026
Merged

style: fix rustfmt and clippy warnings#75
JP-Ellis merged 1 commit into
mainfrom
chore/fix-fmt-clippy

Conversation

@JP-Ellis

Copy link
Copy Markdown
Member

What

Resolve latent rustfmt and clippy issues across the existing codebase. No behavioural change — every edit is a mechanical lint fix.

  • rustfmt (5 diffs): re-wrapped Err(format!(...)) / format! calls and re-indented blocks in src/cli/extension.rs.
  • clippy (-D warnings):
    • clippy::get_firstargs.get(0)args.first() (otel.rs)
    • clippy::needless_return — dropped trailing return (pact_broker_ruby.rs)
    • clippy::let_and_return — return the builder directly (cli.rs)
    • clippy::vec_init_then_pushvec![…] literal (pact_broker_docker.rs)
    • needless borrows / redundant clones / unnecessary Some(…).unwrap() (cli.rs, bin.rs)

Why

The PR-based release migration (#74) adds cargo fmt --check and cargo clippy -- -D warnings gates that the previous CI never ran, so these pre-existing issues were invisible. Landing them here keeps #74 focused purely on the release tooling; #74 will be rebased on top once this merges.

Verification

  • cargo fmt --check — clean
  • cargo clippy --tests --bins -- -D warnings — clean (exit 0)
  • cargo nextest run — 1 passed

The codebase carried latent rustfmt diffs and clippy lints (get_first,
needless_return, let_and_return, vec_init_then_push, redundant clones and
borrows, unnecessary Some/unwrap) that the existing CI never gated on.
Resolve them so the stricter `cargo fmt --check` and `cargo clippy
-D warnings` gates introduced by the release-process migration pass. No
behavioural change.

Assisted-by: Claude Code:claude-opus-4-8[1m]
@JP-Ellis JP-Ellis merged commit 56ec4b8 into main Jun 22, 2026
13 checks passed
@JP-Ellis JP-Ellis deleted the chore/fix-fmt-clippy branch June 22, 2026 23:04
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.

1 participant