@@ -47,6 +47,7 @@ use futures::{
47
47
use futures_channel:: mpsc:: unbounded;
48
48
use move_core_types:: account_address:: AccountAddress ;
49
49
use std:: sync:: Arc ;
50
+ use aptos_types:: on_chain_config:: OnChainConsensusConfig ;
50
51
51
52
#[ async_trait:: async_trait]
52
53
pub trait TExecutionClient : Send + Sync {
@@ -56,6 +57,7 @@ pub trait TExecutionClient: Send + Sync {
56
57
epoch_state : Arc < EpochState > ,
57
58
commit_signer_provider : Arc < dyn CommitSignerProvider > ,
58
59
payload_manager : Arc < PayloadManager > ,
60
+ onchain_consensus_config : & OnChainConsensusConfig ,
59
61
onchain_execution_config : & OnChainExecutionConfig ,
60
62
features : & Features ,
61
63
rand_config : Option < RandConfig > ,
@@ -274,6 +276,7 @@ impl TExecutionClient for ExecutionProxyClient {
274
276
epoch_state : Arc < EpochState > ,
275
277
commit_signer_provider : Arc < dyn CommitSignerProvider > ,
276
278
payload_manager : Arc < PayloadManager > ,
279
+ onchain_consensus_config : & OnChainConsensusConfig ,
277
280
onchain_execution_config : & OnChainExecutionConfig ,
278
281
features : & Features ,
279
282
rand_config : Option < RandConfig > ,
@@ -290,13 +293,14 @@ impl TExecutionClient for ExecutionProxyClient {
290
293
onchain_execution_config. block_executor_onchain_config ( ) ;
291
294
let transaction_deduper =
292
295
create_transaction_deduper ( onchain_execution_config. transaction_deduper_type ( ) ) ;
296
+ let randomness_enabled = onchain_consensus_config. is_vtxn_enabled ( ) && features. is_enabled ( FeatureFlag :: RECONFIGURE_WITH_DKG ) ;
293
297
self . execution_proxy . new_epoch (
294
298
& epoch_state,
295
299
payload_manager,
296
300
transaction_shuffler,
297
301
block_executor_onchain_config,
298
302
transaction_deduper,
299
- features . is_enabled ( FeatureFlag :: RECONFIGURE_WITH_DKG ) ,
303
+ randomness_enabled ,
300
304
) ;
301
305
302
306
maybe_rand_msg_tx
@@ -453,6 +457,7 @@ impl TExecutionClient for DummyExecutionClient {
453
457
_epoch_state : Arc < EpochState > ,
454
458
_commit_signer_provider : Arc < dyn CommitSignerProvider > ,
455
459
_payload_manager : Arc < PayloadManager > ,
460
+ _onchain_consensus_config : & OnChainConsensusConfig ,
456
461
_onchain_execution_config : & OnChainExecutionConfig ,
457
462
_features : & Features ,
458
463
_rand_config : Option < RandConfig > ,
0 commit comments