mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 18:07:58 +00:00
Rename: primitives/sr-io -> primitives/sp-io (#4328)
* primitives/sr-io -> primitives/io * fix * rename * runtime-io -> sp-io * git mv * fix ci * remove package name * fix * fix * try minimizing diff * try minimizing diff again * try minimizing diff again
This commit is contained in:
committed by
Bastian Köcher
parent
1f84d6d41d
commit
4f2cdb20c1
@@ -10,7 +10,7 @@ safe-mix = { version = "1.0.0", default-features = false }
|
||||
codec = { package = "parity-scale-codec", version = "1.0.0", default-features = false, features = ["derive"] }
|
||||
primitives = { package = "sp-core", path = "../../primitives/core", default-features = false }
|
||||
sp-std = { path = "../../primitives/std", default-features = false }
|
||||
runtime-io ={ package = "sp-io", path = "../../primitives/sr-io", default-features = false }
|
||||
sp-io ={ path = "../../primitives/io", default-features = false }
|
||||
sp-runtime = { path = "../../primitives/runtime", default-features = false }
|
||||
sp-version = { path = "../../primitives/sr-version", default-features = false }
|
||||
support = { package = "frame-support", path = "../support", default-features = false }
|
||||
@@ -27,7 +27,7 @@ std = [
|
||||
"codec/std",
|
||||
"primitives/std",
|
||||
"sp-std/std",
|
||||
"runtime-io/std",
|
||||
"sp-io/std",
|
||||
"support/std",
|
||||
"sp-runtime/std",
|
||||
"sp-version/std",
|
||||
|
||||
@@ -80,7 +80,7 @@ impl module::Trait for Runtime {
|
||||
type Event = Event;
|
||||
}
|
||||
|
||||
fn new_test_ext() -> runtime_io::TestExternalities {
|
||||
fn new_test_ext() -> sp_io::TestExternalities {
|
||||
system::GenesisConfig::default().build_storage::<Runtime>().unwrap().into()
|
||||
}
|
||||
|
||||
|
||||
@@ -119,7 +119,7 @@ use support::{
|
||||
use codec::{Encode, Decode};
|
||||
|
||||
#[cfg(any(feature = "std", test))]
|
||||
use runtime_io::TestExternalities;
|
||||
use sp_io::TestExternalities;
|
||||
|
||||
#[cfg(any(feature = "std", test))]
|
||||
use primitives::ChangesTrieConfiguration;
|
||||
@@ -422,11 +422,11 @@ decl_storage! {
|
||||
build(|config: &GenesisConfig| {
|
||||
use codec::Encode;
|
||||
|
||||
runtime_io::storage::set(well_known_keys::CODE, &config.code);
|
||||
runtime_io::storage::set(well_known_keys::EXTRINSIC_INDEX, &0u32.encode());
|
||||
sp_io::storage::set(well_known_keys::CODE, &config.code);
|
||||
sp_io::storage::set(well_known_keys::EXTRINSIC_INDEX, &0u32.encode());
|
||||
|
||||
if let Some(ref changes_trie_config) = config.changes_trie_config {
|
||||
runtime_io::storage::set(
|
||||
sp_io::storage::set(
|
||||
well_known_keys::CHANGES_TRIE_CONFIG,
|
||||
&changes_trie_config.encode(),
|
||||
);
|
||||
@@ -668,9 +668,9 @@ impl<T: Trait> Module<T> {
|
||||
}
|
||||
}
|
||||
|
||||
let storage_root = T::Hash::decode(&mut &runtime_io::storage::root()[..])
|
||||
let storage_root = T::Hash::decode(&mut &sp_io::storage::root()[..])
|
||||
.expect("Node is configured to use the same hash; qed");
|
||||
let storage_changes_root = runtime_io::storage::changes_root(&parent_hash.encode());
|
||||
let storage_changes_root = sp_io::storage::changes_root(&parent_hash.encode());
|
||||
|
||||
// we can't compute changes trie root earlier && put it to the Digest
|
||||
// because it will include all currently existing temporaries.
|
||||
@@ -1187,7 +1187,7 @@ mod tests {
|
||||
|
||||
const CALL: &<Test as Trait>::Call = &();
|
||||
|
||||
fn new_test_ext() -> runtime_io::TestExternalities {
|
||||
fn new_test_ext() -> sp_io::TestExternalities {
|
||||
GenesisConfig::default().build_storage::<Test>().unwrap().into()
|
||||
}
|
||||
|
||||
|
||||
@@ -111,7 +111,7 @@ pub trait SubmitSignedTransaction<T: crate::Trait, Call> {
|
||||
::create_transaction::<Self::Signer>(call, public, id, expected)
|
||||
.ok_or(())?;
|
||||
let xt = Self::Extrinsic::new(call, Some(signature_data)).ok_or(())?;
|
||||
runtime_io::offchain::submit_transaction(xt.encode())
|
||||
sp_io::offchain::submit_transaction(xt.encode())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,7 +126,7 @@ pub trait SubmitUnsignedTransaction<T: crate::Trait, Call> {
|
||||
/// and `Err` if transaction was rejected from the pool.
|
||||
fn submit_unsigned(call: impl Into<Call>) -> Result<(), ()> {
|
||||
let xt = Self::Extrinsic::new(call.into(), None).ok_or(())?;
|
||||
runtime_io::offchain::submit_transaction(xt.encode())
|
||||
sp_io::offchain::submit_transaction(xt.encode())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user