Skip to content
GitHub Actions / clippy succeeded Jun 26, 2024 in 2s

clippy

101 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 101
Note 0
Help 0

Versions

  • rustc 1.74.0 (79e9716c9 2023-11-13)
  • cargo 1.74.0 (ecb9851af 2023-10-18)
  • clippy 0.1.74 (79e9716 2023-11-13)

Annotations

Check warning on line 116 in node/src/cli.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

large size difference between variants

warning: large size difference between variants
   --> node/src/cli.rs:73:1
    |
73  | / pub enum Subcommand {
74  | |     /// Key management cli utilities
75  | |     #[clap(subcommand)]
76  | |     Key(sc_cli::KeySubcommand),
    | |     -------------------------- the second-largest variant contains at least 264 bytes
...   |
115 | |     Benchmark(frame_benchmarking_cli::BenchmarkCmd),
    | |     ----------------------------------------------- the largest variant contains at least 488 bytes
116 | | }
    | |_^ the entire enum is at least 488 bytes
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
    = note: `#[warn(clippy::large_enum_variant)]` on by default
help: consider boxing the large fields to reduce the total size of the enum
    |
115 |     Benchmark(Box<frame_benchmarking_cli::BenchmarkCmd>),
    |               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Check warning on line 100 in node/src/chain_spec/mainnet.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

function `config` is never used

warning: function `config` is never used
   --> node/src/chain_spec/mainnet.rs:100:8
    |
100 | pub fn config(parachain_id: ParaId) -> ChainSpec {
    |        ^^^^^^

Check warning on line 63 in node/src/chain_spec/mainnet.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

function `genesis` is never used

warning: function `genesis` is never used
  --> node/src/chain_spec/mainnet.rs:63:8
   |
63 | pub fn genesis(
   |        ^^^^^^^

Check warning on line 35 in node/src/chain_spec/mainnet.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

function `main_genesis` is never used

warning: function `main_genesis` is never used
  --> node/src/chain_spec/mainnet.rs:35:4
   |
35 | fn main_genesis(
   |    ^^^^^^^^^^^^

Check warning on line 65 in node/src/chain_spec/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

constant `SAFE_XCM_VERSION` is never used

warning: constant `SAFE_XCM_VERSION` is never used
  --> node/src/chain_spec/mod.rs:65:11
   |
65 | pub const SAFE_XCM_VERSION: u32 = xcm::prelude::XCM_VERSION;
   |           ^^^^^^^^^^^^^^^^
   |
   = note: `#[warn(dead_code)]` on by default

Check warning on line 830 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unneeded `return` statement

warning: unneeded `return` statement
   --> runtime/dev/src/lib.rs:830:13
    |
830 |             return (list, storage_info)
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
help: remove `return`
    |
830 |             (list, storage_info)
    |

Check warning on line 547 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/dev/src/lib.rs:547:37
    |
547 |     pub const MinimalBid: Balance = 1 * XRT;
    |                                     ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 395 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/dev/src/lib.rs:395:45
    |
395 |     pub const DataDepositPerByte: Balance = 1 * COASE;
    |                                             ^^^^^^^^^ help: consider reducing it to: `COASE`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 377 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/dev/src/lib.rs:377:46
    |
377 |     pub const PreimageBaseDeposit: Balance = 1 * XRT;
    |                                              ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 245 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/dev/src/lib.rs:245:44
    |
245 |     pub const MinVestedTransfer: Balance = 1 * XRT;
    |                                            ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 191 in runtime/dev/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/dev/src/lib.rs:191:45
    |
191 |     pub const ExistentialDeposit: Balance = 1 * COASE;
    |                                             ^^^^^^^^^ help: consider reducing it to: `COASE`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op
    = note: `#[warn(clippy::identity_op)]` on by default

Check warning on line 857 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unneeded `return` statement

warning: unneeded `return` statement
   --> runtime/main/src/lib.rs:857:13
    |
857 |             return (list, storage_info)
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
    = note: `#[warn(clippy::needless_return)]` on by default
help: remove `return`
    |
857 |             (list, storage_info)
    |

Check warning on line 597 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:597:37
    |
597 |     pub const MinimalBid: Balance = 1 * XRT;
    |                                     ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 404 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:404:45
    |
404 |     pub const DataDepositPerByte: Balance = 1 * COASE;
    |                                             ^^^^^^^^^ help: consider reducing it to: `COASE`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 386 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:386:46
    |
386 |     pub const PreimageBaseDeposit: Balance = 1 * XRT;
    |                                              ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 261 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:261:45
    |
261 |     pub const TransactionByteFee: Balance = 1 * COASE;
    |                                             ^^^^^^^^^ help: consider reducing it to: `COASE`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 243 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:243:44
    |
243 |     pub const MinVestedTransfer: Balance = 1 * XRT;
    |                                            ^^^^^^^ help: consider reducing it to: `XRT`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op

Check warning on line 219 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this operation has no effect

warning: this operation has no effect
   --> runtime/main/src/lib.rs:219:45
    |
219 |     pub const ExistentialDeposit: Balance = 1 * COASE;
    |                                             ^^^^^^^^^ help: consider reducing it to: `COASE`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op
    = note: `#[warn(clippy::identity_op)]` on by default

Check warning on line 117 in runtime/main/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this match could be replaced by its body itself

warning: this match could be replaced by its body itself
   --> runtime/main/src/lib.rs:113:9
    |
113 | /         match call {
114 | |             // These modules are not allowed to be called by transactions:
115 | |             // Other modules should works:
116 | |             _ => true,
117 | |         }
    | |_________^ help: consider using the match body instead: `true`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_single_binding
    = note: `#[warn(clippy::match_single_binding)]` on by default

Check warning on line 202 in runtime/main/src/xcm_config.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

redundant closure

warning: redundant closure
   --> runtime/main/src/xcm_config.rs:202:34
    |
202 |                 calls.iter().all(|call| Self::allow_base_call(call))
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `Self::allow_base_call`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure

Check warning on line 199 in runtime/main/src/xcm_config.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

redundant closure

warning: redundant closure
   --> runtime/main/src/xcm_config.rs:199:34
    |
199 |                 calls.iter().all(|call| Self::allow_base_call(call))
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `Self::allow_base_call`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure
    = note: `#[warn(clippy::redundant_closure)]` on by default

Check warning on line 97 in runtime/main/src/xcm_config.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

using `clone` on type `MultiLocation` which implements the `Copy` trait

warning: using `clone` on type `MultiLocation` which implements the `Copy` trait
  --> runtime/main/src/xcm_config.rs:97:18
   |
97 |             Some(location.clone())
   |                  ^^^^^^^^^^^^^^^^ help: try dereferencing it: `*location`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
   = note: `#[warn(clippy::clone_on_copy)]` on by default

Check warning on line 309 in node/service/src/parachain.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (9/7)

warning: this function has too many arguments (9/7)
   --> node/service/src/parachain.rs:298:1
    |
298 |   #[sc_tracing::logging::prefix_logs_with("Parachain")]
    |   ^----------------------------------------------------
    |   |
    |  _in this procedural macro expansion
    | |
299 | | pub async fn new_service<RuntimeApi, RB, BIQ, BIC>(
300 | |     parachain_config: Configuration,
301 | |     polkadot_config: Configuration,
...   |
308 | |     hwbench: Option<sc_sysinfo::HwBench>,
309 | | ) -> sc_service::error::Result<(TaskManager, Arc<ParachainClient<RuntimeApi>>)>
    | |_______________________________________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments
    = note: this warning originates in the attribute macro `sc_tracing::logging::prefix_logs_with` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 254 in node/service/src/parachain.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> node/service/src/parachain.rs:254:13
    |
254 |             &config,
    |             ^^^^^^^ help: change this to: `config`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow

Check warning on line 210 in node/service/src/parachain.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

very complex type used. Consider factoring parts into `type` definitions

warning: very complex type used. Consider factoring parts into `type` definitions
   --> node/service/src/parachain.rs:196:6
    |
196 |   ) -> Result<
    |  ______^
197 | |     PartialComponents<
198 | |         ParachainClient<RuntimeApi>,
199 | |         ParachainBackend,
...   |
209 | |     sc_service::Error,
210 | | >
    | |_^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity