Skip to content

feat: pallet assets pop api integration #84

feat: pallet assets pop api integration

feat: pallet assets pop api integration #84

Triggered via pull request June 20, 2024 16:38
@DaanvdplasDaanvdplas
synchronize #71
Status Success
Total duration 11s
Artifacts

lint-pr.yml

on: pull_request_target
Validate PR title for conventional commit compliance
2s
Validate PR title for conventional commit compliance
Fit to window
Zoom out
Zoom in

Annotations

6 warnings
large size difference between variants: node/src/cli.rs#L5
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 512 bytes ... | 48 | | Key(sc_cli::KeySubcommand), 49 | | } | |_^ the entire enum is at least 512 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>), | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
this match could be replaced by its body itself: runtime/devnet/src/extensions.rs#L77
warning: this match could be replaced by its body itself --> runtime/devnet/src/extensions.rs:77:2 | 77 | / match error { 78 | | _ => { 79 | | let mut encoded_error = error.encode(); 80 | | // Resize the encoded value to 4 bytes in order to decode the value in a u32 (4 bytes). ... | 83 | | }, 84 | | } | |_____^ | = 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 help: consider using the match body instead | 77 ~ { 78 ~ let mut encoded_error = error.encode(); 79 ~ // Resize the encoded value to 4 bytes in order to decode the value in a u32 (4 bytes). 80 ~ encoded_error.resize(4, 0); 81 ~ u32::decode(&mut &encoded_error[..]).unwrap() 82 ~ } |
bound is defined in more than one place: runtime/devnet/src/extensions.rs#L54
warning: bound is defined in more than one place --> runtime/devnet/src/extensions.rs:54:10 | 54 | fn call<E: Ext>(&mut self, env: Environment<E, InitState>) -> Result<RetVal, DispatchError> | ^ 55 | where 56 | E: Ext<T = T>, | ^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations = note: `#[warn(clippy::multiple_bound_locations)]` on by default
bound is defined in more than one place: runtime/testnet/src/extensions.rs#L44
warning: bound is defined in more than one place --> runtime/testnet/src/extensions.rs:44:10 | 44 | fn call<E: Ext>(&mut self, env: Environment<E, InitState>) -> Result<RetVal, DispatchError> | ^ 45 | where 46 | E: Ext<T = T>, | ^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations = note: `#[warn(clippy::multiple_bound_locations)]` on by default
used a field initializer for a tuple struct: scripts/fund-dev-accounts/./main.rs#L54
warning: used a field initializer for a tuple struct --> scripts/fund-dev-accounts/./main.rs:54:9 | 54 | id: AssetId { 0: Location { parents: 0, interior: Junctions::Here } }, | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `AssetId(Location { parents: 0, interior: Junctions::Here })` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#init_numbered_fields
used a field initializer for a tuple struct: scripts/fund-dev-accounts/./main.rs#L52
warning: used a field initializer for a tuple struct --> scripts/fund-dev-accounts/./main.rs:52:36 | 52 | let assets = VersionedAssets::V4(Assets { | __________________________________________^ 53 | | 0: vec![Asset { 54 | | id: AssetId { 0: Location { parents: 0, interior: Junctions::Here } }, 55 | | fun: amount, 56 | | }], 57 | | }); | |_________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#init_numbered_fields = note: `#[warn(clippy::init_numbered_fields)]` on by default help: try | 52 ~ let assets = VersionedAssets::V4(Assets(<[_]>::into_vec( 53 + // This rustc_box is not required, but it produces a dramatic improvement in compile 54 + // time when constructing arrays with many elements. 55 + #[rustc_box] 56 + $crate::boxed::Box::new([$($x),+]) 57 ~ ))); |