Skip to content

Commit

Permalink
Fix inactive_votes_cache.election_start
Browse files Browse the repository at this point in the history
An election for send2 could start from activate_successors, on occassion.
Disabling activate successors to avoid that.
  • Loading branch information
dsiganos committed Apr 26, 2024
1 parent d15849e commit 98f231f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion nano/core_test/active_transactions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,9 @@ TEST (inactive_votes_cache, election_start)
nano::node_config node_config = system.default_config ();
node_config.frontiers_confirmation = nano::frontiers_confirmation_mode::disabled;
node_config.optimistic_scheduler.enabled = false;
auto & node = *system.add_node (node_config);
nano::node_flags node_flags;
node_flags.disable_activate_successors = true; // without this, an election can start for send2 on occasion
auto & node = *system.add_node (node_config, node_flags);
nano::block_hash latest (node.latest (nano::dev::genesis_key.pub));
nano::keypair key1, key2;
nano::send_block_builder send_block_builder;
Expand Down

0 comments on commit 98f231f

Please sign in to comment.