Skip to content

Commit

Permalink
Fix generate_genesis_state (#1317)
Browse files Browse the repository at this point in the history
  • Loading branch information
hqwangningbo authored Jul 26, 2024
1 parent 9e37e32 commit 14da5c8
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 9 deletions.
12 changes: 7 additions & 5 deletions node/service/src/collator_kusama.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,13 @@ use sp_keystore::KeystorePtr;
use substrate_prometheus_endpoint::Registry;

#[cfg(not(feature = "runtime-benchmarks"))]
type HostFunctions = sp_io::SubstrateHostFunctions;
type HostFunctions = cumulus_client_service::ParachainHostFunctions;

#[cfg(feature = "runtime-benchmarks")]
type HostFunctions =
(sp_io::SubstrateHostFunctions, frame_benchmarking::benchmarking::HostFunctions);

type HostFunctions = (
cumulus_client_service::ParachainHostFunctions,
frame_benchmarking::benchmarking::HostFunctions,
);
pub type FullBackend = TFullBackend<Block>;
pub type FullClient = TFullClient<Block, RuntimeApi, WasmExecutor<HostFunctions>>;
pub type MaybeFullSelectChain = Option<LongestChain<FullBackend, Block>>;
Expand Down Expand Up @@ -100,10 +101,11 @@ pub fn new_partial(
.build();

let (client, backend, keystore_container, task_manager) =
sc_service::new_full_parts::<Block, RuntimeApi, _>(
sc_service::new_full_parts_record_import::<Block, RuntimeApi, _>(
config,
telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()),
executor,
true,
)?;
let client = Arc::new(client);

Expand Down
11 changes: 7 additions & 4 deletions node/service/src/collator_polkadot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,13 @@ use sp_keystore::KeystorePtr;
use substrate_prometheus_endpoint::Registry;

#[cfg(not(feature = "runtime-benchmarks"))]
type HostFunctions = sp_io::SubstrateHostFunctions;
type HostFunctions = cumulus_client_service::ParachainHostFunctions;

#[cfg(feature = "runtime-benchmarks")]
type HostFunctions =
(sp_io::SubstrateHostFunctions, frame_benchmarking::benchmarking::HostFunctions);
type HostFunctions = (
cumulus_client_service::ParachainHostFunctions,
frame_benchmarking::benchmarking::HostFunctions,
);

pub type FullBackend = TFullBackend<Block>;
pub type FullClient = TFullClient<Block, RuntimeApi, WasmExecutor<HostFunctions>>;
Expand Down Expand Up @@ -100,10 +102,11 @@ pub fn new_partial(
.build();

let (client, backend, keystore_container, task_manager) =
sc_service::new_full_parts::<Block, RuntimeApi, _>(
sc_service::new_full_parts_record_import::<Block, RuntimeApi, _>(
config,
telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()),
executor,
true,
)?;
let client = Arc::new(client);

Expand Down

0 comments on commit 14da5c8

Please sign in to comment.