Skip to content

Commit

Permalink
Merge #4893
Browse files Browse the repository at this point in the history
4893: Do not notify consensus about historical blocks r=EdHastingsCasperAssociation a=fizyk20

What it says on the tin. This should also stop consensus from emitting the log message about missing eras.

Closes #4378 


Co-authored-by: Bartłomiej Kamiński <[email protected]>
  • Loading branch information
casperlabs-bors-ng[bot] and fizyk20 authored Sep 24, 2024
2 parents ea5e6fa + d14054d commit 6be9ce5
Showing 1 changed file with 3 additions and 15 deletions.
18 changes: 3 additions & 15 deletions node/src/reactor/main_reactor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1553,21 +1553,9 @@ impl MainReactor {
),
));
}
MetaBlock::Historical(historical_meta_block) => {
// Header type is the same for now so we can use the same `BlockAdded` event;
// When the header will be versioned, a new event will be needed for the
// consensus component.
effects.extend(reactor::wrap_effects(
MainEvent::Consensus,
self.consensus.handle_event(
effect_builder,
rng,
consensus::Event::BlockAdded {
header: Box::new(historical_meta_block.block.clone_header()),
header_hash: *historical_meta_block.block.hash(),
},
),
));
MetaBlock::Historical(_historical_meta_block) => {
// Historical meta blocks aren't of interest to consensus - consensus only
// cares about new blocks. Hence, we can just do nothing here.
}
}
}
Expand Down

0 comments on commit 6be9ce5

Please sign in to comment.