xxx: Include DispatchError and use balanace_transfer_with_params

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
This commit is contained in:
Alexandru Vasile
2023-03-08 17:30:26 +02:00
parent 2f17c5cf1d
commit 0583e902b3
68 changed files with 110587 additions and 2 deletions
@@ -24,7 +24,8 @@ use subxt::{
OnlineClient,
};
#[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")]
// #[subxt::subxt(runtime_metadata_path = "../artifacts/polkadot_metadata.scale")]
#[subxt::subxt(runtime_metadata_path = "../artifacts/Balances.scale")]
pub mod polkadot {}
#[tokio::main]
@@ -40,7 +41,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
// Create a transaction to submit:
let tx = polkadot::tx()
.balances()
.transfer(dest, 123_456_789_012_345);
.transfer(dest, 123_456_789_012_345)
.unvalidated();
// Configure the transaction tip and era:
let tx_params = Params::new()