Skip to content

Commit

Permalink
fix(sidecar): review logs on commitment deadline
Browse files Browse the repository at this point in the history
  • Loading branch information
thedevbirb committed Nov 12, 2024
1 parent ee021ff commit d00f2cc
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions bolt-sidecar/src/driver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -374,13 +374,15 @@ impl<C: StateFetcher, ECDSA: SignerECDSA> SidecarDriver<C, ECDSA> {
/// Handle a commitment deadline event, submitting constraints to the Constraints client service
/// and starting to build a local payload for the given target slot.
async fn handle_commitment_deadline(&mut self, slot: u64) {
debug!(slot, "Commitment deadline reached, building local block");

let Some(template) = self.execution.get_block_template(slot) else {
warn!("No block template found for slot {slot} when requested");
// Nothing to do then. Block templates are created only when constraints are added,
// which means we haven't issued any commitment for this slot because we are
// (probably) not the proposer for this block.
return;
};

info!(slot, "Commitment deadline reached, building local block");

if let Err(e) = self.local_builder.build_new_local_payload(slot, template).await {
error!(err = ?e, "Error while building local payload at deadline for slot {slot}");
};
Expand Down

0 comments on commit d00f2cc

Please sign in to comment.