Companion for paritytech/polkadot#6744: Retire OldV1SessionInfo (#2213)

* Adjust commands

* Use `NetworkWorker::next_action()` instead of `poll()`

* rustfmt

* minor: fix mutability

* Move imports

* Replace `NetworkWorker::next_action()` with `run()`

* Import fix

* Make `NetworkWorker::run` consume self

* Retire `OldV1SessionInfo`

* update lockfile for {"polkadot", "substrate"}

* update lockfile for {"substrate", "polkadot"}

* update lockfile for {"substrate", "polkadot"}

* Make stuff compile

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Piotr Mikołajczyk <piomiko41@gmail.com>
Co-authored-by: Dmitry Markin <dmitry@markin.tech>
Co-authored-by: parity-processbot <>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
s0me0ne-unkn0wn
2023-02-20 21:26:47 +01:00
committed by GitHub
parent 242c111099
commit 9ed57cf859
6 changed files with 323 additions and 308 deletions
+12 -2
View File
@@ -229,9 +229,12 @@ pub fn run() -> Result<()> {
},
#[cfg(feature = "try-runtime")]
Some(Subcommand::TryRuntime(cmd)) => {
use parachain_template_runtime::MILLISECS_PER_BLOCK;
use sc_executor::{sp_wasm_interface::ExtendedHostFunctions, NativeExecutionDispatch};
use try_runtime_cli::block_building_info::timestamp_with_aura_info;
let runner = cli.create_runner(cmd)?;
use sc_executor::{sp_wasm_interface::ExtendedHostFunctions, NativeExecutionDispatch};
type HostFunctionsOf<E> = ExtendedHostFunctions<
sp_io::SubstrateHostFunctions,
<E as NativeExecutionDispatch>::ExtendHostFunctions,
@@ -243,8 +246,15 @@ pub fn run() -> Result<()> {
sc_service::TaskManager::new(runner.config().tokio_handle.clone(), *registry)
.map_err(|e| format!("Error: {:?}", e))?;
let info_provider = timestamp_with_aura_info(MILLISECS_PER_BLOCK);
runner.async_run(|_| {
Ok((cmd.run::<Block, HostFunctionsOf<ParachainNativeExecutor>>(), task_manager))
Ok((
cmd.run::<Block, HostFunctionsOf<ParachainNativeExecutor>, _>(Some(
info_provider,
)),
task_manager,
))
})
},
#[cfg(not(feature = "try-runtime"))]