default timestamp bump 1 sec

This commit is contained in:
Sina Mahmoodi 2024-08-14 13:09:50 +02:00
parent c0d5dfb011
commit e3cd999230

View file

@ -344,7 +344,7 @@ func (sim *simulator) makeHeaders(blocks []simBlock) ([]*types.Header, error) {
} }
overrides := block.BlockOverrides overrides := block.BlockOverrides
if overrides.Time == nil { if overrides.Time == nil {
t := prevTimestamp + 12 t := prevTimestamp + 1
overrides.Time = (*hexutil.Uint64)(&t) overrides.Time = (*hexutil.Uint64)(&t)
} else if time := (*uint64)(overrides.Time); *time <= prevTimestamp { } else if time := (*uint64)(overrides.Time); *time <= prevTimestamp {
return nil, &invalidBlockTimestampError{fmt.Sprintf("block timestamps must be in order: %d <= %d", *time, prevTimestamp)} return nil, &invalidBlockTimestampError{fmt.Sprintf("block timestamps must be in order: %d <= %d", *time, prevTimestamp)}