mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 02:57:57 +00:00
Remove unneeded Config bounds and BlockNumber associated type (#804)
* remove unneeded Config bounds and BlockNumber associated type * clippy and fmt
This commit is contained in:
@@ -107,6 +107,6 @@ fn codegen(
|
||||
type_substitutes,
|
||||
crate_path,
|
||||
);
|
||||
println!("{}", runtime_api);
|
||||
println!("{runtime_api}");
|
||||
Ok(())
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ async fn handle_pallet_metadata(nodes: &[Uri], name: &str) -> color_eyre::Result
|
||||
Some(pallet_metadata) => {
|
||||
let hash = get_pallet_hash(&metadata.types, pallet_metadata);
|
||||
let hex_hash = hex::encode(hash);
|
||||
println!("Node {:?} has pallet metadata hash {:?}", node, hex_hash);
|
||||
println!("Node {node:?} has pallet metadata hash {hex_hash:?}");
|
||||
|
||||
compatibility
|
||||
.pallet_present
|
||||
@@ -93,7 +93,7 @@ async fn handle_full_metadata(nodes: &[Uri]) -> color_eyre::Result<()> {
|
||||
let metadata = fetch_runtime_metadata(node).await?;
|
||||
let hash = get_metadata_hash(&metadata);
|
||||
let hex_hash = hex::encode(hash);
|
||||
println!("Node {:?} has metadata hash {:?}", node, hex_hash,);
|
||||
println!("Node {node:?} has metadata hash {hex_hash:?}",);
|
||||
|
||||
compatibility_map
|
||||
.entry(hex_hash)
|
||||
|
||||
@@ -37,11 +37,11 @@ pub async fn run(opts: Opts) -> color_eyre::Result<()> {
|
||||
let bytes = hex::decode(hex_data.trim_start_matches("0x"))?;
|
||||
let metadata = <RuntimeMetadataPrefixed as Decode>::decode(&mut &bytes[..])?;
|
||||
let json = serde_json::to_string_pretty(&metadata)?;
|
||||
println!("{}", json);
|
||||
println!("{json}");
|
||||
Ok(())
|
||||
}
|
||||
"hex" => {
|
||||
println!("{}", hex_data);
|
||||
println!("{hex_data}");
|
||||
Ok(())
|
||||
}
|
||||
"bytes" => {
|
||||
|
||||
Reference in New Issue
Block a user