mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-20 18:35:41 +00:00
Normalize Crate Names in SRML/Node Template (#3543)
* Fix some instances of `runtime-io` * Patch a bunch * More patches for consistancy * more patch * Fix various build issues * Fix tests * Patch `srml-support-*` crates * Fix doc tests * Revert "Fix doc tests" This reverts commit ba2ec61da7acc36821a70e76a31a6a5bf13bbe95. * Revert "Patch `srml-support-*` crates" This reverts commit 9a6070450107dec17784ba34af4b871023f6dc81. * Missed one * Fix doc tests
This commit is contained in:
@@ -15,7 +15,7 @@ sr-primitives = { path = "../../core/sr-primitives", default-features = false }
|
||||
runtime-io = { package = "sr-io", path = "../../core/sr-io", default-features = false }
|
||||
rstd = { package = "sr-std", path = "../../core/sr-std", default-features = false }
|
||||
sandbox = { package = "sr-sandbox", path = "../../core/sr-sandbox", default-features = false }
|
||||
srml-support = { path = "../support", default-features = false }
|
||||
support = { package = "srml-support", path = "../support", default-features = false }
|
||||
system = { package = "srml-system", path = "../system", default-features = false }
|
||||
timestamp = { package = "srml-timestamp", path = "../timestamp", default-features = false }
|
||||
|
||||
@@ -39,7 +39,7 @@ std = [
|
||||
"runtime-io/std",
|
||||
"rstd/std",
|
||||
"sandbox/std",
|
||||
"srml-support/std",
|
||||
"support/std",
|
||||
"system/std",
|
||||
"timestamp/std",
|
||||
"parity-wasm/std",
|
||||
|
||||
@@ -26,8 +26,8 @@ use rstd::collections::btree_map::{BTreeMap, Entry};
|
||||
use rstd::prelude::*;
|
||||
use runtime_io::blake2_256;
|
||||
use sr_primitives::traits::{Bounded, Zero};
|
||||
use srml_support::traits::{Currency, Get, Imbalance, SignedImbalance, UpdateBalanceOutcome};
|
||||
use srml_support::{storage::child, StorageMap};
|
||||
use support::traits::{Currency, Get, Imbalance, SignedImbalance, UpdateBalanceOutcome};
|
||||
use support::{storage::child, StorageMap};
|
||||
use system;
|
||||
|
||||
// Note: we don't provide Option<Contract> because we can't create
|
||||
|
||||
@@ -22,7 +22,7 @@ use crate::rent;
|
||||
|
||||
use rstd::prelude::*;
|
||||
use sr_primitives::traits::{Bounded, CheckedAdd, CheckedSub, Zero};
|
||||
use srml_support::traits::{WithdrawReason, Currency};
|
||||
use support::traits::{WithdrawReason, Currency};
|
||||
use timestamp;
|
||||
|
||||
pub type AccountIdOf<T> = <T as system::Trait>::AccountId;
|
||||
|
||||
@@ -18,8 +18,8 @@ use crate::{GasSpent, Module, Trait, BalanceOf, NegativeImbalanceOf};
|
||||
use rstd::convert::TryFrom;
|
||||
use sr_primitives::BLOCK_FULL;
|
||||
use sr_primitives::traits::{CheckedMul, Zero, SaturatedConversion, SimpleArithmetic, UniqueSaturatedInto};
|
||||
use srml_support::StorageValue;
|
||||
use srml_support::traits::{Currency, ExistenceRequirement, Get, Imbalance, OnUnbalanced, WithdrawReason};
|
||||
use support::StorageValue;
|
||||
use support::traits::{Currency, ExistenceRequirement, Get, Imbalance, OnUnbalanced, WithdrawReason};
|
||||
|
||||
#[cfg(test)]
|
||||
use std::{any::Any, fmt::Debug};
|
||||
|
||||
@@ -103,12 +103,12 @@ use runtime_io::blake2_256;
|
||||
use sr_primitives::traits::{
|
||||
Hash, StaticLookup, Zero, MaybeSerializeDebug, Member
|
||||
};
|
||||
use srml_support::dispatch::{Result, Dispatchable};
|
||||
use srml_support::{
|
||||
use support::dispatch::{Result, Dispatchable};
|
||||
use support::{
|
||||
Parameter, StorageMap, StorageValue, decl_module, decl_event, decl_storage, storage::child,
|
||||
parameter_types,
|
||||
};
|
||||
use srml_support::traits::{OnFreeBalanceZero, OnUnbalanced, Currency, Get};
|
||||
use support::traits::{OnFreeBalanceZero, OnUnbalanced, Currency, Get};
|
||||
use system::{ensure_signed, RawOrigin, ensure_root};
|
||||
use primitives::storage::well_known_keys::CHILD_STORAGE_KEY_PREFIX;
|
||||
use timestamp;
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
use crate::{BalanceOf, ContractInfo, ContractInfoOf, TombstoneContractInfo, Trait, AliveContractInfo};
|
||||
use sr_primitives::traits::{Bounded, CheckedDiv, CheckedMul, Saturating, Zero,
|
||||
SaturatedConversion};
|
||||
use srml_support::traits::{Currency, ExistenceRequirement, Get, WithdrawReason};
|
||||
use srml_support::StorageMap;
|
||||
use support::traits::{Currency, ExistenceRequirement, Get, WithdrawReason};
|
||||
use support::StorageMap;
|
||||
|
||||
#[derive(PartialEq, Eq, Copy, Clone)]
|
||||
#[must_use]
|
||||
|
||||
@@ -33,7 +33,7 @@ use runtime_io::with_externalities;
|
||||
use sr_primitives::testing::{Digest, DigestItem, Header, UintAuthorityId, H256};
|
||||
use sr_primitives::traits::{BlakeTwo256, Hash, IdentityLookup};
|
||||
use sr_primitives::{Perbill, BuildStorage};
|
||||
use srml_support::{
|
||||
use support::{
|
||||
assert_ok, assert_err, impl_outer_dispatch, impl_outer_event, impl_outer_origin, parameter_types,
|
||||
storage::child, StorageMap, StorageValue, traits::{Currency, Get},
|
||||
};
|
||||
@@ -49,7 +49,7 @@ mod contract {
|
||||
// needs to give a name for the current crate.
|
||||
// This hack is required for `impl_outer_event!`.
|
||||
pub use super::super::*;
|
||||
use srml_support::impl_outer_event;
|
||||
use support::impl_outer_event;
|
||||
}
|
||||
impl_outer_event! {
|
||||
pub enum MetaEvent for Test {
|
||||
|
||||
@@ -31,7 +31,7 @@ use crate::wasm::{prepare, runtime::Env, PrefabWasmModule};
|
||||
use crate::{CodeHash, CodeStorage, PristineCode, Schedule, Trait};
|
||||
use rstd::prelude::*;
|
||||
use sr_primitives::traits::{Hash, Bounded};
|
||||
use srml_support::StorageMap;
|
||||
use support::StorageMap;
|
||||
|
||||
/// Gas metering token that used for charging storing code into the code storage.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user