Update Substrate & Polkadot (#84)

This commit is contained in:
Bastian Köcher
2020-04-29 14:23:18 +02:00
committed by GitHub
parent 06a36a6650
commit 5f008af15f
15 changed files with 398 additions and 406 deletions
+1 -1
View File
@@ -28,13 +28,13 @@ sp-io = { git = "https://github.com/paritytech/substrate", branch = "cumulus-bra
sp-core = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sp-inherents = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sp-consensus = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-consensus = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-cli = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-executor = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-service = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sp-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-network = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-client = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-basic-authorship = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch", version = "0.8.0-alpha.5" }
sp-timestamp = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
sc-finality-grandpa = { git = "https://github.com/paritytech/substrate", branch = "cumulus-branch" }
+3 -2
View File
@@ -134,6 +134,7 @@ parameter_types! {
pub const AvailableBlockRatio: Perbill = Perbill::from_percent(75);
pub const MaximumBlockLength: u32 = 5 * 1024 * 1024;
pub const Version: RuntimeVersion = VERSION;
pub const ExtrinsicBaseWeight: Weight = 10_000_000;
}
impl frame_system::Trait for Runtime {
@@ -173,6 +174,8 @@ impl frame_system::Trait for Runtime {
type OnNewAccount = ();
type OnKilledAccount = Balances;
type DbWeight = ();
type ExtrinsicBaseWeight = ExtrinsicBaseWeight;
type BlockExecutionWeight = ();
}
parameter_types! {
@@ -201,7 +204,6 @@ parameter_types! {
pub const ExistentialDeposit: u128 = 500;
pub const TransferFee: u128 = 0;
pub const CreationFee: u128 = 0;
pub const TransactionBaseFee: u128 = 0;
pub const TransactionByteFee: u128 = 1;
}
@@ -218,7 +220,6 @@ impl pallet_balances::Trait for Runtime {
impl pallet_transaction_payment::Trait for Runtime {
type Currency = Balances;
type OnTransactionPayment = ();
type TransactionBaseFee = TransactionBaseFee;
type TransactionByteFee = TransactionByteFee;
type WeightToFee = ConvertInto;
type FeeMultiplierUpdate = ();
+3 -5
View File
@@ -23,11 +23,9 @@ use sc_cli::{
CliConfiguration, Error, ImportParams, KeystoreParams, NetworkParams, Result, SharedParams,
SubstrateCli,
};
use sc_client::genesis;
use sc_service::client::genesis;
use sc_network::config::TransportConfig;
use sc_service::{
config::{NetworkConfiguration, NodeKeyConfig, PrometheusConfig},
};
use sc_service::config::{NetworkConfiguration, NodeKeyConfig, PrometheusConfig};
use sp_core::hexdisplay::HexDisplay;
use sp_runtime::{
traits::{Block as BlockT, Hash as HashT, Header as HeaderT},
@@ -129,7 +127,7 @@ pub fn run() -> Result<()> {
let storage = (&chain_spec::get_chain_spec()).build_storage()?;
let child_roots = storage.children.iter().map(|(sk, child_content)| {
let child_roots = storage.children_default.iter().map(|(sk, child_content)| {
let state_root =
<<<Block as BlockT>::Header as HeaderT>::Hashing as HashT>::trie_root(
child_content.data.clone().into_iter().collect(),
+1 -1
View File
@@ -48,7 +48,7 @@ macro_rules! new_full_start {
parachain_runtime::RuntimeApi,
crate::service::Executor,
>($config)?
.with_select_chain(|_config, backend| Ok(sc_client::LongestChain::new(backend.clone())))?
.with_select_chain(|_config, backend| Ok(sc_consensus::LongestChain::new(backend.clone())))?
.with_transaction_pool(|config, client, _fetcher, prometheus_registry| {
let pool_api = Arc::new(sc_transaction_pool::FullChainApi::new(client.clone()));
let pool = sc_transaction_pool::BasicPool::new(config, pool_api, prometheus_registry);