Fix cli for structopt 0.3.7 and pin to that version (#4509)

* Fix cli for structopt 0.3.7 and pin to that version

This is just some hotfix to make everything compile. In the future it
will require another pr to not depend on internals of StructOpt, but
that will probably also require some additions to StructOpt itself. To
not break the code again with another StructOpt, this also pins the
StructOpt version.

* Fix benches

* Fix for fix
This commit is contained in:
Bastian Köcher
2019-12-28 22:52:18 +01:00
committed by GitHub
parent 9876d3dd09
commit 56355879be
10 changed files with 68 additions and 85 deletions
+2 -8
View File
@@ -20,8 +20,8 @@ use tokio::runtime::{Builder as RuntimeBuilder, Runtime};
use sc_cli::{IntoExit, NoCustom, SharedParams, ImportParams, error};
use sc_service::{AbstractService, Roles as ServiceRoles, Configuration};
use log::info;
use structopt::{StructOpt, clap::App};
use sc_cli::{display_role, parse_and_prepare, AugmentClap, GetSharedParams, ParseAndPrepare};
use structopt::StructOpt;
use sc_cli::{display_role, parse_and_prepare, GetSharedParams, ParseAndPrepare};
use crate::{service, ChainSpec, load_spec};
use crate::factory_impl::FactoryState;
use node_transaction_factory::RuntimeAdapter;
@@ -88,12 +88,6 @@ pub struct FactoryCmd {
pub import_params: ImportParams,
}
impl AugmentClap for FactoryCmd {
fn augment_clap<'a, 'b>(app: App<'a, 'b>) -> App<'a, 'b> {
FactoryCmd::augment_clap(app)
}
}
/// Parse command line arguments into service configuration.
pub fn run<I, T, E>(args: I, exit: E, version: sc_cli::VersionInfo) -> error::Result<()> where
I: IntoIterator<Item = T>,