mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-09 15:37:56 -05:00
add log (#2390)
This commit is contained in:
@@ -24,6 +24,10 @@ var (
|
||||
Name: "regsync_received_blocks",
|
||||
Help: "The number of received blocks",
|
||||
})
|
||||
forkedBlock = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "regsync_received_forked_blocks",
|
||||
Help: "The number of received forked blocks",
|
||||
})
|
||||
recBlockAnnounce = promauto.NewCounter(prometheus.CounterOpts{
|
||||
Name: "regsync_received_block_announce",
|
||||
Help: "The number of received block announcements",
|
||||
|
||||
@@ -192,7 +192,8 @@ func (rs *RegularSync) validateAndProcessBlock(
|
||||
return nil, nil, false, err
|
||||
}
|
||||
} else {
|
||||
log.Errorf("Received Block from a Forked Chain %#x with slot %d", blockRoot, block.Slot)
|
||||
forkedBlock.Inc()
|
||||
log.Warnf("Received Block from a Forked Chain with root %#x and slot %d", blockRoot, block.Slot)
|
||||
}
|
||||
|
||||
sentBlocks.Inc()
|
||||
|
||||
Reference in New Issue
Block a user