mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 22:47:56 +00:00
Migrate node (cli, executor, primitives and runtime) to the 2018 edition (#1589)
This commit is contained in:
committed by
Gav Wood
parent
d796e09f02
commit
473721f959
@@ -23,6 +23,7 @@ use node_runtime::{ConsensusConfig, CouncilSeatsConfig, CouncilVotingConfig, Dem
|
||||
SudoConfig, ContractConfig, GrandpaConfig, IndicesConfig, Permill, Perbill};
|
||||
pub use node_runtime::GenesisConfig;
|
||||
use substrate_service;
|
||||
use hex_literal::{hex, hex_impl};
|
||||
|
||||
use substrate_keystore::pad_seed;
|
||||
|
||||
@@ -303,7 +304,7 @@ pub fn local_testnet_config() -> ChainSpec {
|
||||
mod tests {
|
||||
use super::*;
|
||||
use service_test;
|
||||
use service::Factory;
|
||||
use crate::service::Factory;
|
||||
|
||||
fn local_testnet_genesis_instant() -> GenesisConfig {
|
||||
let mut genesis = local_testnet_genesis();
|
||||
|
||||
@@ -17,6 +17,9 @@
|
||||
//! Initialization errors.
|
||||
|
||||
use client;
|
||||
use error_chain::{
|
||||
error_chain, error_chain_processing, impl_error_chain_processed
|
||||
};
|
||||
|
||||
error_chain! {
|
||||
foreign_links {
|
||||
|
||||
@@ -19,32 +19,6 @@
|
||||
#![warn(missing_docs)]
|
||||
#![warn(unused_extern_crates)]
|
||||
|
||||
extern crate tokio;
|
||||
|
||||
extern crate substrate_cli as cli;
|
||||
extern crate substrate_primitives as primitives;
|
||||
extern crate node_runtime;
|
||||
extern crate exit_future;
|
||||
#[macro_use]
|
||||
extern crate hex_literal;
|
||||
#[cfg(test)]
|
||||
extern crate substrate_service_test as service_test;
|
||||
extern crate substrate_transaction_pool as transaction_pool;
|
||||
#[macro_use]
|
||||
extern crate substrate_network as network;
|
||||
extern crate substrate_consensus_aura as consensus;
|
||||
extern crate substrate_client as client;
|
||||
extern crate substrate_finality_grandpa as grandpa;
|
||||
extern crate node_primitives;
|
||||
#[macro_use]
|
||||
extern crate substrate_service;
|
||||
extern crate node_executor;
|
||||
extern crate substrate_keystore;
|
||||
extern crate substrate_inherents as inherents;
|
||||
|
||||
#[macro_use]
|
||||
extern crate log;
|
||||
|
||||
pub use cli::error;
|
||||
pub mod chain_spec;
|
||||
mod service;
|
||||
@@ -54,6 +28,7 @@ use tokio::runtime::Runtime;
|
||||
pub use cli::{VersionInfo, IntoExit, NoCustom};
|
||||
use substrate_service::{ServiceFactory, Roles as ServiceRoles};
|
||||
use std::ops::Deref;
|
||||
use log::info;
|
||||
|
||||
/// The chain specification option.
|
||||
#[derive(Clone, Debug)]
|
||||
|
||||
@@ -34,6 +34,9 @@ use substrate_service::{
|
||||
};
|
||||
use transaction_pool::{self, txpool::{Pool as TransactionPool}};
|
||||
use inherents::InherentDataProviders;
|
||||
use network::construct_simple_protocol;
|
||||
use substrate_service::construct_service_factory;
|
||||
use log::info;
|
||||
|
||||
construct_simple_protocol! {
|
||||
/// Demo protocol attachment for substrate.
|
||||
|
||||
Reference in New Issue
Block a user