Skip to content

Commit

Permalink
Lower deposit finalization error to warning (sigp#3739)
Browse files Browse the repository at this point in the history
## Issue Addressed

Partially addresses sigp#3707

## Proposed Changes

Drop `ERRO` log to `WARN` until we identify the exact conditions that lead to this case.

Add a message which hopefully reassures users who only see this log once 😅 

Add the block hash to the error message in case it will prove useful in debugging the root cause.
  • Loading branch information
michaelsproul authored and macladson committed Dec 30, 2022
1 parent 826bd38 commit 3925691
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions beacon_node/eth1/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -751,10 +751,11 @@ impl Service {
let deposit_count_to_finalize = eth1data_to_finalize.deposit_count;
if deposit_count_to_finalize > already_finalized {
match self.finalize_deposits(eth1data_to_finalize) {
Err(e) => error!(
Err(e) => warn!(
self.log,
"Failed to finalize deposit cache";
"error" => ?e,
"info" => "this should resolve on its own"
),
Ok(()) => info!(
self.log,
Expand Down Expand Up @@ -814,9 +815,10 @@ impl Service {
.block_by_hash(&eth1_data.block_hash)
.cloned()
.ok_or_else(|| {
Error::FailedToFinalizeDeposit(
"Finalized block not found in block cache".to_string(),
)
Error::FailedToFinalizeDeposit(format!(
"Finalized block not found in block cache: {:?}",
eth1_data.block_hash
))
})?;
self.inner
.deposit_cache
Expand Down

0 comments on commit 3925691

Please sign in to comment.