From 09931874ef9b0d2ae3db90f4e42d393e45a5c4ef Mon Sep 17 00:00:00 2001 From: Jerry Date: Tue, 18 Jun 2024 17:54:30 +0200 Subject: [PATCH] Add timestamp limit to validium This fixes bug where timestamp limit is always 0 in validium recovery mode --- zk/l1_data/l1_decoder.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/zk/l1_data/l1_decoder.go b/zk/l1_data/l1_decoder.go index 24bf36458c4..840516783e4 100644 --- a/zk/l1_data/l1_decoder.go +++ b/zk/l1_data/l1_decoder.go @@ -122,6 +122,11 @@ func DecodeL1BatchData(txData []byte, daUrl string) ([][]byte, common.Address, u return nil, common.Address{}, 0, fmt.Errorf("expected position 3 in the l1 call data to be address") } coinbase = cb + ts, ok := data[1].(uint64) + if !ok { + return nil, common.Address{}, 0, fmt.Errorf("expected position 1 in the l1 call data to be the limit timestamp") + } + limitTimstamp = ts default: return nil, common.Address{}, 0, fmt.Errorf("unknown l1 call data") }