Skip to content

Commit db0ce45

Browse files
authored
fix(anvil): latest evm version should be prague (#10653)
* fix(`anvil`): latest evm version should be prague * fix test * nit
1 parent 65650a6 commit db0ce45

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

crates/anvil/src/cmd.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ pub struct NodeArgs {
7979

8080
/// The EVM hardfork to use.
8181
///
82-
/// Choose the hardfork by name, e.g. `cancun`, `shanghai`, `paris`, `london`, etc...
82+
/// Choose the hardfork by name, e.g. `prague`, `cancun`, `shanghai`, `paris`, `london`, etc...
8383
/// [default: latest]
8484
#[arg(long)]
8585
pub hardfork: Option<String>,

crates/anvil/src/config.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -525,15 +525,15 @@ impl NodeConfig {
525525
/// Returns the hardfork to use
526526
pub fn get_hardfork(&self) -> ChainHardfork {
527527
if self.odyssey {
528-
return ChainHardfork::Ethereum(EthereumHardfork::Prague);
528+
return ChainHardfork::Ethereum(EthereumHardfork::default());
529529
}
530530
if let Some(hardfork) = self.hardfork {
531531
return hardfork;
532532
}
533533
if self.enable_optimism {
534-
return OpHardfork::Isthmus.into();
534+
return OpHardfork::default().into();
535535
}
536-
EthereumHardfork::Cancun.into()
536+
EthereumHardfork::default().into()
537537
}
538538

539539
/// Sets a custom code size limit

crates/anvil/tests/it/anvil_api.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ async fn can_get_node_info() {
449449

450450
let block_number = provider.get_block_number().await.unwrap();
451451
let block = provider.get_block(BlockId::from(block_number)).await.unwrap().unwrap();
452-
let hard_fork: &str = SpecId::CANCUN.into();
452+
let hard_fork: &str = SpecId::PRAGUE.into();
453453

454454
let expected_node_info = NodeInfo {
455455
current_block_number: 0_u64,

0 commit comments

Comments
 (0)