mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 19:17:58 +00:00
[big refactor] Remove crate aliasing. (#4395)
* Rename: Phase 1. * Unify codec. * Fixing: Phase 2 * Fixing: Phase 3. * Fixing: Phase 4. * Fixing: Phase 5. * Fixing: Phase 6. * Fixing: Phase 7. * Fixing: Phase 8. Tests * Fixing: Phase 9. Tests!!! * Fixing: Phase 10. Moar tests! * Finally done! * More fixes. * Rename primitives:: to sp_core:: * Apply renames in finality-grandpa. * Fix benches. * Fix benches 2. * Revert node-template. * Fix frame-system in our modules.
This commit is contained in:
committed by
Gavin Wood
parent
f14d98a439
commit
8778ca7dc8
@@ -22,19 +22,19 @@ use rand::{Rng, SeedableRng};
|
||||
use rand::rngs::StdRng;
|
||||
|
||||
use codec::{Encode, Decode};
|
||||
use keyring::sr25519::Keyring;
|
||||
use sp_keyring::sr25519::Keyring;
|
||||
use node_runtime::{
|
||||
Call, CheckedExtrinsic, UncheckedExtrinsic, SignedExtra, BalancesCall, ExistentialDeposit,
|
||||
MinimumPeriod
|
||||
};
|
||||
use node_primitives::Signature;
|
||||
use primitives::{sr25519, crypto::Pair};
|
||||
use sp_core::{sr25519, crypto::Pair};
|
||||
use sp_runtime::{
|
||||
generic::Era, traits::{Block as BlockT, Header as HeaderT, SignedExtension, Verify, IdentifyAccount}
|
||||
};
|
||||
use node_transaction_factory::RuntimeAdapter;
|
||||
use node_transaction_factory::modes::Mode;
|
||||
use inherents::InherentData;
|
||||
use sp_inherents::InherentData;
|
||||
use sp_timestamp;
|
||||
use sp_finality_tracker;
|
||||
|
||||
@@ -56,12 +56,12 @@ type Number = <<node_primitives::Block as BlockT>::Header as HeaderT>::Number;
|
||||
impl<Number> FactoryState<Number> {
|
||||
fn build_extra(index: node_primitives::Index, phase: u64) -> node_runtime::SignedExtra {
|
||||
(
|
||||
system::CheckVersion::new(),
|
||||
system::CheckGenesis::new(),
|
||||
system::CheckEra::from(Era::mortal(256, phase)),
|
||||
system::CheckNonce::from(index),
|
||||
system::CheckWeight::new(),
|
||||
transaction_payment::ChargeTransactionPayment::from(0),
|
||||
frame_system::CheckVersion::new(),
|
||||
frame_system::CheckGenesis::new(),
|
||||
frame_system::CheckEra::from(Era::mortal(256, phase)),
|
||||
frame_system::CheckNonce::from(index),
|
||||
frame_system::CheckWeight::new(),
|
||||
pallet_transaction_payment::ChargeTransactionPayment::from(0),
|
||||
Default::default(),
|
||||
)
|
||||
}
|
||||
@@ -149,7 +149,7 @@ impl RuntimeAdapter for FactoryState<Number> {
|
||||
signed: Some((sender.clone(), Self::build_extra(index, phase))),
|
||||
function: Call::Balances(
|
||||
BalancesCall::transfer(
|
||||
indices::address::Address::Id(destination.clone().into()),
|
||||
pallet_indices::address::Address::Id(destination.clone().into()),
|
||||
(*amount).into()
|
||||
)
|
||||
)
|
||||
@@ -253,7 +253,7 @@ fn sign<RA: RuntimeAdapter>(
|
||||
}
|
||||
}).into();
|
||||
UncheckedExtrinsic {
|
||||
signature: Some((indices::address::Address::Id(signed), signature, extra)),
|
||||
signature: Some((pallet_indices::address::Address::Id(signed), signature, extra)),
|
||||
function: payload.0,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user