mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 17:31:05 +00:00
Support decoding signed extensions (#1209)
* skeleton commit * signed extension decoding * fix some minor things * make api more similar to Extrinsics * defer decoding of signed extensions * fix byte slices * add test for nonce signed extension * adjust test and extend for tip * clippy * support both ChargeTransactionPayment and ChargeAssetTxPayment * address PR comments * Extend lifetimes, expose pub structs, remove as_type * add signed extensions to block subscribing example * make example less ugly --------- Co-authored-by: James Wilson <james@jsdw.me>
This commit is contained in:
@@ -48,6 +48,16 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
println!(" {pallet_name}_{event_name}");
|
||||
println!(" {}", event_values);
|
||||
}
|
||||
|
||||
println!(" Signed Extensions:");
|
||||
if let Some(signed_extensions) = ext.signed_extensions() {
|
||||
for signed_extension in signed_extensions.iter() {
|
||||
let signed_extension = signed_extension?;
|
||||
let name = signed_extension.name();
|
||||
let value = signed_extension.value()?.to_string();
|
||||
println!(" {name}: {value}");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user