Skip to content

Commit 5b40ad3

Browse files
committed
Add replay_transactions config option to miner so it constructs replay blocks when a threshold number of signers tell it to
Signed-off-by: Jacinta Ferrant <jacinta.ferrant@gmail.com>
1 parent 3255b72 commit 5b40ad3

File tree

6 files changed

+618
-273
lines changed

6 files changed

+618
-273
lines changed

stackslib/src/chainstate/nakamoto/miner.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -541,6 +541,7 @@ impl NakamotoBlockBuilder {
541541
settings: BlockBuilderSettings,
542542
event_observer: Option<&dyn MemPoolEventDispatcher>,
543543
signer_bitvec_len: u16,
544+
replay_transactions: &[StacksTransaction],
544545
) -> Result<BlockMetadata, Error> {
545546
let (tip_consensus_hash, tip_block_hash, tip_height) = (
546547
parent_stacks_header.consensus_hash.clone(),
@@ -622,10 +623,11 @@ impl NakamotoBlockBuilder {
622623
settings,
623624
event_observer,
624625
ASTRules::PrecheckSize,
626+
replay_transactions,
625627
) {
626628
Ok(x) => x,
627629
Err(e) => {
628-
warn!("Failure building block: {}", e);
630+
warn!("Failure building block: {e}");
629631
tenure_tx.rollback_block();
630632
return Err(e);
631633
}

0 commit comments

Comments
 (0)