Skip to content

feat: add interfaces & error for psp22 #1340

feat: add interfaces & error for psp22

feat: add interfaces & error for psp22 #1340

GitHub Actions / clippy succeeded Sep 24, 2024 in 3s

clippy

167 warnings

Details

Results

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

Versions

  • rustc 1.81.0 (eeb90cda1 2024-09-04)
  • cargo 1.81.0 (2dbb1af80 2024-08-20)
  • clippy 0.1.81 (eeb90cd 2024-09-04)

Annotations

Check warning on line 44 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:5:1
   |
5  | / pub enum Subcommand {
6  | |     /// Build a chain specification.
7  | |     BuildSpec(sc_cli::BuildSpecCmd),
...  |
19 | |     ImportBlocks(sc_cli::ImportBlocksCmd),
   | |     ------------------------------------- the second-largest variant contains at least 240 bytes
...  |
39 | |     Benchmark(frame_benchmarking_cli::BenchmarkCmd),
   | |     ----------------------------------------------- the largest variant contains at least 544 bytes
...  |
43 | |     Key(sc_cli::KeySubcommand),
44 | | }
   | |_^ the entire enum is at least 544 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
   |
39 |     Benchmark(Box<frame_benchmarking_cli::BenchmarkCmd>),
   |               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Check warning on line 916 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a function

warning: missing documentation for a function
   --> runtime/mainnet/src/lib.rs:680:1
    |
680 | / impl_runtime_apis! {
681 | |
682 | |     impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
683 | |         fn slot_duration() -> sp_consensus_aura::SlotDuration {
...   |
915 | |     }
916 | | }
    | |_^
    |
    = note: this warning originates in the macro `impl_runtime_apis` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 136 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a constant

warning: missing documentation for a constant
   --> runtime/mainnet/src/lib.rs:136:2
    |
136 |     pub const MILLICENTS: Balance = CENTS / 1_000; // 100_000
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Check warning on line 135 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a constant

warning: missing documentation for a constant
   --> runtime/mainnet/src/lib.rs:135:2
    |
135 |     pub const CENTS: Balance = MILLIUNIT * 10; // 100_000_000
    |     ^^^^^^^^^^^^^^^^^^^^^^^^

Check warning on line 124 in runtime/mainnet/src/config/xcm.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
   --> runtime/mainnet/src/config/xcm.rs:124:1
    |
124 | pub struct XcmConfig;
    | ^^^^^^^^^^^^^^^^^^^^

Check warning on line 117 in runtime/mainnet/src/config/xcm.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a type alias

warning: missing documentation for a type alias
   --> runtime/mainnet/src/config/xcm.rs:117:1
    |
117 | pub type TrustedReserves = (NativeAsset, NativeAssetFrom<AssetHub>);
    | ^^^^^^^^^^^^^^^^^^^^^^^^

Check warning on line 93 in runtime/mainnet/src/config/xcm.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a type alias

warning: missing documentation for a type alias
  --> runtime/mainnet/src/config/xcm.rs:93:1
   |
93 | pub type Barrier = TrailingSetTopicAsId<(
   | ^^^^^^^^^^^^^^^^

Check warning on line 265 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:86:1
   |
86 | / parameter_types! {
87 | |     // One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
88 | |     pub UnitWeightCost: Weight = Weight::from_parts(1_000_000_000, 64 * 1024);
89 | |     pub const MaxInstructions: u32 = 100;
90 | |     pub const MaxAssetsIntoHolding: u32 = 64;
91 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 265 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:86:1
   |
86 | / parameter_types! {
87 | |     // One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
88 | |     pub UnitWeightCost: Weight = Weight::from_parts(1_000_000_000, 64 * 1024);
89 | |     pub const MaxInstructions: u32 = 100;
90 | |     pub const MaxAssetsIntoHolding: u32 = 64;
91 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 277 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:86:1
   |
86 | / parameter_types! {
87 | |     // One XCM operation is 1_000_000_000 weight - almost certainly a conservative estimate.
88 | |     pub UnitWeightCost: Weight = Weight::from_parts(1_000_000_000, 64 * 1024);
89 | |     pub const MaxInstructions: u32 = 100;
90 | |     pub const MaxAssetsIntoHolding: u32 = 64;
91 | | }
   | |_^
   |
   = note: this warning originates in the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 277 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:31:1
   |
31 | / parameter_types! {
32 | |     pub const RelayLocation: Location = Location::parent();
33 | |     pub AssetHub: Location = Location::new(1, [Parachain(1000)]);
34 | |     pub const RelayNetwork: Option<NetworkId> = Some(Polkadot);
35 | |     pub RelayChainOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into();
36 | |     pub UniversalLocation: InteriorLocation = [GlobalConsensus(RelayNetwork::get().unwrap()), Parachain(ParachainInfo::parachain_id().int...
37 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 277 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:31:1
   |
31 | / parameter_types! {
32 | |     pub const RelayLocation: Location = Location::parent();
33 | |     pub AssetHub: Location = Location::new(1, [Parachain(1000)]);
34 | |     pub const RelayNetwork: Option<NetworkId> = Some(Polkadot);
35 | |     pub RelayChainOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into();
36 | |     pub UniversalLocation: InteriorLocation = [GlobalConsensus(RelayNetwork::get().unwrap()), Parachain(ParachainInfo::parachain_id().int...
37 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 265 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:31:1
   |
31 | / parameter_types! {
32 | |     pub const RelayLocation: Location = Location::parent();
33 | |     pub AssetHub: Location = Location::new(1, [Parachain(1000)]);
34 | |     pub const RelayNetwork: Option<NetworkId> = Some(Polkadot);
35 | |     pub RelayChainOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into();
36 | |     pub UniversalLocation: InteriorLocation = [GlobalConsensus(RelayNetwork::get().unwrap()), Parachain(ParachainInfo::parachain_id().int...
37 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 277 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:31:1
   |
31 | / parameter_types! {
32 | |     pub const RelayLocation: Location = Location::parent();
33 | |     pub AssetHub: Location = Location::new(1, [Parachain(1000)]);
34 | |     pub const RelayNetwork: Option<NetworkId> = Some(Polkadot);
35 | |     pub RelayChainOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into();
36 | |     pub UniversalLocation: InteriorLocation = [GlobalConsensus(RelayNetwork::get().unwrap()), Parachain(ParachainInfo::parachain_id().int...
37 | | }
   | |_^
   |
   = note: this warning originates in the macro `$crate::parameter_types` which comes from the expansion of the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 265 in /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frame-support-36.0.0/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
  --> runtime/mainnet/src/config/xcm.rs:31:1
   |
31 | / parameter_types! {
32 | |     pub const RelayLocation: Location = Location::parent();
33 | |     pub AssetHub: Location = Location::new(1, [Parachain(1000)]);
34 | |     pub const RelayNetwork: Option<NetworkId> = Some(Polkadot);
35 | |     pub RelayChainOrigin: RuntimeOrigin = cumulus_pallet_xcm::Origin::Relay.into();
36 | |     pub UniversalLocation: InteriorLocation = [GlobalConsensus(RelayNetwork::get().unwrap()), Parachain(ParachainInfo::parachain_id().int...
37 | | }
   | |_^
   |
   = note: this warning originates in the macro `parameter_types` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 2 in runtime/mainnet/src/config/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a module

warning: missing documentation for a module
 --> runtime/mainnet/src/config/mod.rs:2:1
  |
2 | pub mod xcm;
  | ^^^^^^^^^^^

Check warning on line 916 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a module

warning: missing documentation for a module
   --> runtime/mainnet/src/lib.rs:680:1
    |
680 | / impl_runtime_apis! {
681 | |
682 | |     impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
683 | |         fn slot_duration() -> sp_consensus_aura::SlotDuration {
...   |
915 | |     }
916 | | }
    | |_^
    |
    = note: this warning originates in the macro `impl_runtime_apis` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 916 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a constant

warning: missing documentation for a constant
   --> runtime/mainnet/src/lib.rs:680:1
    |
680 | / impl_runtime_apis! {
681 | |
682 | |     impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
683 | |         fn slot_duration() -> sp_consensus_aura::SlotDuration {
...   |
915 | |     }
916 | | }
    | |_^
    |
    = note: this warning originates in the macro `impl_runtime_apis` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 916 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
   --> runtime/mainnet/src/lib.rs:680:1
    |
680 | / impl_runtime_apis! {
681 | |
682 | |     impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
683 | |         fn slot_duration() -> sp_consensus_aura::SlotDuration {
...   |
915 | |     }
916 | | }
    | |_^
    |
    = note: this warning originates in the macro `impl_runtime_apis` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for an associated function

warning: missing documentation for an associated function
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a type alias

warning: missing documentation for a type alias
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct field

warning: missing documentation for a struct field
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a variant

warning: missing documentation for a variant
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for an enum

warning: missing documentation for an enum
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)

Check warning on line 587 in runtime/mainnet/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

missing documentation for a struct

warning: missing documentation for a struct
   --> runtime/mainnet/src/lib.rs:587:1
    |
587 | #[frame_support::runtime]
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: this warning originates in the attribute macro `frame_support::runtime` (in Nightly builds, run with -Z macro-backtrace for more info)