Skip to content

Commit

Permalink
fix(cmd): initialize StaticFileProducer with config PruneModes un…
Browse files Browse the repository at this point in the history
…wind command (#13791)
  • Loading branch information
joshieDo authored Jan 13, 2025
1 parent d761ac4 commit df00877
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions crates/cli/commands/src/stage/unwind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ use reth_provider::{
providers::ProviderNodeTypes, BlockExecutionWriter, BlockNumReader, ChainStateBlockReader,
ChainStateBlockWriter, ProviderFactory, StaticFileProviderFactory, StorageLocation,
};
use reth_prune::PruneModes;
use reth_stages::{
sets::{DefaultStages, OfflineStages},
stages::ExecutionStage,
Expand Down Expand Up @@ -120,7 +119,7 @@ impl<C: ChainSpecParser<ChainSpec: EthChainSpec + EthereumHardforks>> Command<C>

let builder = if self.offline {
Pipeline::<N>::builder().add_stages(
OfflineStages::new(executor, config.stages, PruneModes::default())
OfflineStages::new(executor, config.stages, prune_modes.clone())
.builder()
.disable(reth_stages::StageId::SenderRecovery),
)
Expand All @@ -145,15 +144,15 @@ impl<C: ChainSpecParser<ChainSpec: EthChainSpec + EthereumHardforks>> Command<C>
max_duration: None,
},
stage_conf.execution_external_clean_threshold(),
prune_modes,
prune_modes.clone(),
ExExManagerHandle::empty(),
)),
)
};

let pipeline = builder.build(
provider_factory.clone(),
StaticFileProducer::new(provider_factory, PruneModes::default()),
StaticFileProducer::new(provider_factory, prune_modes),
);
Ok(pipeline)
}
Expand Down

0 comments on commit df00877

Please sign in to comment.