From 0d46387b7bd8292ac42a5f687634273d13db1724 Mon Sep 17 00:00:00 2001 From: William Smith Date: Thu, 27 Jun 2024 11:04:32 -0700 Subject: [PATCH] [StateAccumulatorV2] Re-enable on testnet --- .../src/authority/epoch_start_configuration.rs | 2 +- crates/sui-core/src/state_accumulator.rs | 12 ++++-------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/crates/sui-core/src/authority/epoch_start_configuration.rs b/crates/sui-core/src/authority/epoch_start_configuration.rs index c8c9374b1fc2e6..4a35b467a5fb53 100644 --- a/crates/sui-core/src/authority/epoch_start_configuration.rs +++ b/crates/sui-core/src/authority/epoch_start_configuration.rs @@ -61,7 +61,7 @@ impl EpochFlag { /// For situations in which there is no config available (e.g. setting up a downloaded snapshot). pub fn default_for_no_config() -> Vec { - Self::default_flags_impl(&Default::default(), false) + Self::default_flags_impl(&Default::default(), true) } fn default_flags_impl( diff --git a/crates/sui-core/src/state_accumulator.rs b/crates/sui-core/src/state_accumulator.rs index 0cc6f6c9d4e3c2..f585e4e18671af 100644 --- a/crates/sui-core/src/state_accumulator.rs +++ b/crates/sui-core/src/state_accumulator.rs @@ -367,15 +367,11 @@ impl StateAccumulator { store: Arc, epoch_store: &Arc, ) -> Self { - if cfg!(msim) { - if epoch_store.state_accumulator_v2_enabled() { - return StateAccumulator::V2(StateAccumulatorV2::new(store)); - } else { - return StateAccumulator::V1(StateAccumulatorV1::new(store)); - } + if epoch_store.state_accumulator_v2_enabled() { + return StateAccumulator::V2(StateAccumulatorV2::new(store)); + } else { + return StateAccumulator::V1(StateAccumulatorV1::new(store)); } - - StateAccumulator::V1(StateAccumulatorV1::new(store)) } /// Accumulates the effects of a single checkpoint and persists the accumulator.