Skip to content

Commit

Permalink
Fix/frontier block import (#136)
Browse files Browse the repository at this point in the history
* fix: remove frontier_block_import to fix syncing issue polkadot-evm/frontier#603
  • Loading branch information
peterwht authored Aug 15, 2023
1 parent f58e7c5 commit 77adabf
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions node/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ use sp_runtime::{app_crypto::AppCrypto, traits::BlakeTwo256};
use substrate_prometheus_endpoint::Registry;

// Frontier
use fc_consensus::FrontierBlockImport;
use fc_mapping_sync::{kv::MappingSyncWorker, SyncStrategy};
use fc_rpc::EthTask;
use fc_rpc_core::types::{FeeHistoryCache, FilterPool};
Expand Down Expand Up @@ -106,13 +105,10 @@ type ParachainExecutor<Executor> = NativeElseWasmExecutor<Executor>;
pub type ParachainClient<RuntimeApi, Executor> =
TFullClient<Block, RuntimeApi, ParachainExecutor<Executor>>;
type ParachainBackend = TFullBackend<Block>;
// Does NOT have FrontierBlockImport for the following issue: https://github.com/paritytech/frontier/issues/603
type ParachainBlockImport<RuntimeApi, Executor> = TParachainBlockImport<
Block,
FrontierBlockImport<
Block,
Arc<TFullClient<Block, RuntimeApi, ParachainExecutor<Executor>>>,
TFullClient<Block, RuntimeApi, ParachainExecutor<Executor>>,
>,
Arc<TFullClient<Block, RuntimeApi, ParachainExecutor<Executor>>>,
ParachainBackend,
>;

Expand Down Expand Up @@ -203,9 +199,7 @@ where

let frontier_backend = crate::rpc::open_frontier_backend(client.clone(), config)?;

let frontier_block_import = FrontierBlockImport::new(client.clone(), client.clone());

let parachain_block_import = TParachainBlockImport::new(frontier_block_import, backend.clone());
let parachain_block_import = TParachainBlockImport::new(client.clone(), backend.clone());

let import_queue = build_import_queue(
client.clone(),
Expand Down

0 comments on commit 77adabf

Please sign in to comment.