Skip to content

Commit

Permalink
Remove fatal log (0xPolygonHermez#1295)
Browse files Browse the repository at this point in the history
  • Loading branch information
ToniRamirezM authored Oct 14, 2022
1 parent fc67a71 commit a480ece
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions aggregator/aggregator.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,20 +101,20 @@ func (a *Aggregator) Start(ctx context.Context) {
}

func (a *Aggregator) tryToSendVerifiedBatch(ctx context.Context, ticker *time.Ticker) {
log.Info("checking if network is synced")
log.Debug("checking if network is synced")
for !a.isSynced(ctx) {
log.Infof("waiting for synchronizer to sync...")
waitTick(ctx, ticker)
continue
}
log.Info("checking if there is any consolidated batch to be verified")
log.Debug("checking if there is any consolidated batch to be verified")
lastVerifiedBatch, err := a.State.GetLastVerifiedBatch(ctx, nil)
if err != nil && err != state.ErrNotFound {
log.Warnf("failed to get last consolidated batch, err: %v", err)
waitTick(ctx, ticker)
return
} else if err == state.ErrNotFound {
log.Info("no consolidated batch found")
log.Debug("no consolidated batch found")
waitTick(ctx, ticker)
return
}
Expand Down
2 changes: 1 addition & 1 deletion ethtxmanager/ethtxmanager.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ func (c *Client) VerifyBatch(batchNum uint64, resGetProof *pb.GetProofResponse)
log.Infof("tx %s reached timeout, retrying with gas price = %d", tx.Hash(), gasPrice)
continue
}
log.Fatalf("tx %s failed, err: %w", tx.Hash(), err)
log.Errorf("tx %s failed, err: %w", tx.Hash(), err)
} else {
log.Infof("batch verification sent to L1 successfully. Tx hash: %s", tx.Hash())
return
Expand Down

0 comments on commit a480ece

Please sign in to comment.