Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates several Rust CLI and test/support crates to satisfy newly promoted Clippy lints under Rust 1.97 (notably around redundant borrows in formatting, to_string() in format args, and uninlined format args), keeping make check green without intended behavior changes.
Changes:
- Removes redundant references (
&...) in format arguments across multiple crates. - Drops an unnecessary
.to_string()in a formatting context for identity overwrite messaging. - Uses Rust’s inline format argument syntax in a
println!call.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| cmd/soroban-cli/src/commands/tx/fetch/result.rs | Inlines a println! format arg to satisfy uninlined_format_args. |
| cmd/soroban-cli/src/commands/keys/generate.rs | Removes redundant borrow and .to_string() in overwrite identity message formatting. |
| cmd/soroban-cli/src/commands/keys/add.rs | Same formatting cleanup for overwrite identity message. |
| cmd/soroban-cli/src/commands/container/start.rs | Removes redundant borrow in a formatted “Starting network” info message. |
| cmd/crates/soroban-test/tests/it/build.rs | Removes redundant borrow in cargo_home.display() formatting used for path prefixing. |
| cmd/crates/soroban-test/src/lib.rs | Removes redundant borrows when formatting RPC header key/value into an env var string. |
| cmd/crates/soroban-spec-tools/src/contract.rs | Removes redundant borrow in a writeln! formatting argument for docs output. |
Ryang-21
approved these changes
Jul 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Fixes new clippy lint failures introduced by the Rust 1.97 upgrade so
make checkpasses again. Removes redundant references in format arguments, drops a.to_string()call on aDisplaytype, and inlines a format argument across 7 files.Why
Rust 1.97 promotes several clippy lints (
useless_borrows_in_formatting,to_string_in_format_args,uninlined_format_args) that broke the build under-D clippy::all. These are mechanical, no-behavior-change fixes to keep the lint gate green.Known limitations
N/A