Skip to content

Commit

Permalink
Store Local Exit Root (0xPolygonHermez#485)
Browse files Browse the repository at this point in the history
* Store Local Exit Root

* comment fixes

* comment fixes
  • Loading branch information
ToniRamirezM authored Mar 16, 2022
1 parent 096221f commit 4f31c2f
Show file tree
Hide file tree
Showing 9 changed files with 94 additions and 58 deletions.
6 changes: 4 additions & 2 deletions cmd/register.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ func registerSequencer(ctx *cli.Context) error {
tr := tree.NewStateTree(mt, scCodeStore)

stateCfg := state.Config{
DefaultChainID: c.NetworkConfig.L2DefaultChainID,
MaxCumulativeGasUsed: c.NetworkConfig.MaxCumulativeGasUsed,
DefaultChainID: c.NetworkConfig.L2DefaultChainID,
MaxCumulativeGasUsed: c.NetworkConfig.MaxCumulativeGasUsed,
L2GlobalExitRootManagerAddr: c.NetworkConfig.L2GlobalExitRootManagerAddr,
L2GlobalExitRootManagerPosition: c.NetworkConfig.L2GlobalExitRootManagerPosition,
}

stateDb := pgstatestorage.NewPostgresStorage(sqlDB)
Expand Down
6 changes: 4 additions & 2 deletions cmd/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,10 @@ func start(ctx *cli.Context) error {
tr := tree.NewStateTree(mt, scCodeStore)

stateCfg := state.Config{
DefaultChainID: c.NetworkConfig.L2DefaultChainID,
MaxCumulativeGasUsed: c.NetworkConfig.MaxCumulativeGasUsed,
DefaultChainID: c.NetworkConfig.L2DefaultChainID,
MaxCumulativeGasUsed: c.NetworkConfig.MaxCumulativeGasUsed,
L2GlobalExitRootManagerAddr: c.NetworkConfig.L2GlobalExitRootManagerAddr,
L2GlobalExitRootManagerPosition: c.NetworkConfig.L2GlobalExitRootManagerPosition,
}

stateDb := pgstatestorage.NewPostgresStorage(sqlDB)
Expand Down
2 changes: 2 additions & 0 deletions config/network-config.example.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
"genBlockNumber": 1,
"poeAddr": "0xCf7Ed3AccA5a467e9e704C703E8D87F634fB0Fc9",
"maticAddr": "0x37AffAf737C3683aB73F6E1B0933b725Ab9796Aa",
"l2globalExitRootManagerAddr": "0x0000000000000000000000000000000000000000",
"l2globalExitRootManagerPosition": 2,
"l1ChainID": 1337,
"l2DefaultChainID": 1000,
"balances": {
Expand Down
94 changes: 54 additions & 40 deletions config/network.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,29 @@ import (

//NetworkConfig is the configuration struct for the different environments
type NetworkConfig struct {
Arity uint8
GenBlockNumber uint64
PoEAddr common.Address
MaticAddr common.Address
L1ChainID uint64
L2DefaultChainID uint64
Balances map[common.Address]*big.Int
MaxCumulativeGasUsed uint64
Arity uint8
GenBlockNumber uint64
PoEAddr common.Address
MaticAddr common.Address
L2GlobalExitRootManagerAddr common.Address
L2GlobalExitRootManagerPosition uint64
L1ChainID uint64
L2DefaultChainID uint64
Balances map[common.Address]*big.Int
MaxCumulativeGasUsed uint64
}

type networkConfigFromJSON struct {
Arity uint8 `json:"arity"`
GenBlockNumber uint64 `json:"genBlockNumber"`
PoEAddr string `json:"poeAddr"`
MaticAddr string `json:"maticAddr"`
L1ChainID uint64 `json:"l1ChainID"`
L2DefaultChainID uint64 `json:"l2DefaultChainID"`
Balances map[string]string `json:"balances"`
MaxCumulativeGasUsed uint64 `json:"maxCumulativeGasUsed"`
Arity uint8 `json:"arity"`
GenBlockNumber uint64 `json:"genBlockNumber"`
PoEAddr string `json:"poeAddr"`
MaticAddr string `json:"maticAddr"`
L2GlobalExitRootManagerAddr string `json:"l2globalExitRootManagerAddr"`
L2GlobalExitRootManagerPosition uint64 `json:"l2globalExitRootManagerPosition"`
L1ChainID uint64 `json:"l1ChainID"`
L2DefaultChainID uint64 `json:"l2DefaultChainID"`
Balances map[string]string `json:"balances"`
MaxCumulativeGasUsed uint64 `json:"maxCumulativeGasUsed"`
}

const (
Expand All @@ -46,38 +50,44 @@ const (
//nolint:gomnd
var (
mainnetConfig = NetworkConfig{
Arity: 4,
GenBlockNumber: 13808430,
PoEAddr: common.HexToAddress("0x11D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"),
MaticAddr: common.HexToAddress("0x37AffAf737C3683aB73F6E1B0933b725Ab9796Aa"),
L1ChainID: 1, //Mainnet
L2DefaultChainID: 10000,
Arity: 4,
GenBlockNumber: 13808430,
PoEAddr: common.HexToAddress("0x11D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"),
MaticAddr: common.HexToAddress("0x37AffAf737C3683aB73F6E1B0933b725Ab9796Aa"),
L2GlobalExitRootManagerAddr: common.HexToAddress("0x0000000000000000000000000000000000000000"),
L2GlobalExitRootManagerPosition: 2,
L1ChainID: 1, //Mainnet
L2DefaultChainID: 10000,
Balances: map[common.Address]*big.Int{
common.HexToAddress("0xb1D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"): big.NewInt(1000),
common.HexToAddress("0xb1D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FB"): big.NewInt(2000),
},
MaxCumulativeGasUsed: 800000,
}
testnetConfig = NetworkConfig{
Arity: 4,
GenBlockNumber: 9817974,
PoEAddr: common.HexToAddress("0x21D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"),
MaticAddr: common.HexToAddress("0x37AffAf737C3683aB73F6E1B0933b725Ab9796Aa"),
L1ChainID: 4, //Rinkeby
L2DefaultChainID: 40000,
Arity: 4,
GenBlockNumber: 9817974,
PoEAddr: common.HexToAddress("0x21D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"),
MaticAddr: common.HexToAddress("0x37AffAf737C3683aB73F6E1B0933b725Ab9796Aa"),
L2GlobalExitRootManagerAddr: common.HexToAddress("0x0000000000000000000000000000000000000000"),
L2GlobalExitRootManagerPosition: 2,
L1ChainID: 4, //Rinkeby
L2DefaultChainID: 40000,
Balances: map[common.Address]*big.Int{
common.HexToAddress("0xb1D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FA"): big.NewInt(1000),
common.HexToAddress("0xb1D0Dc8E2Ce3a93EB2b32f4C7c3fD9dDAf1211FB"): big.NewInt(2000),
},
MaxCumulativeGasUsed: 800000,
}
internalTestnetConfig = NetworkConfig{
Arity: 4,
GenBlockNumber: 6279130,
PoEAddr: common.HexToAddress("0xaD9d51A5B5237aC36cF9d5f78EA84F8a79d3a274"),
MaticAddr: common.HexToAddress("0xA8d4b3CA3e49dCE738E5E29DfcF78499FE7312C9"),
L1ChainID: 5, //Goerli
L2DefaultChainID: 1000,
Arity: 4,
GenBlockNumber: 6279130,
PoEAddr: common.HexToAddress("0xaD9d51A5B5237aC36cF9d5f78EA84F8a79d3a274"),
MaticAddr: common.HexToAddress("0xA8d4b3CA3e49dCE738E5E29DfcF78499FE7312C9"),
L2GlobalExitRootManagerAddr: common.HexToAddress("0x0000000000000000000000000000000000000000"),
L2GlobalExitRootManagerPosition: 2,
L1ChainID: 5, //Goerli
L2DefaultChainID: 1000,
Balances: map[common.Address]*big.Int{
common.HexToAddress("0x617b3a3528F9cDd6630fd3301B9c8911F7Bf063D"): bigIntFromBase10String("1000000000000000000000"),
common.HexToAddress("0x4d5Cf5032B2a844602278b01199ED191A86c93ff"): bigIntFromBase10String("1000000000000000000000"),
Expand Down Expand Up @@ -120,12 +130,14 @@ var (
MaxCumulativeGasUsed: 800000,
}
localConfig = NetworkConfig{
Arity: 4,
GenBlockNumber: 1,
PoEAddr: common.HexToAddress("0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9"),
MaticAddr: common.HexToAddress("0x5FbDB2315678afecb367f032d93F642f64180aa3"),
L1ChainID: 1337,
L2DefaultChainID: 1000,
Arity: 4,
GenBlockNumber: 1,
PoEAddr: common.HexToAddress("0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9"),
MaticAddr: common.HexToAddress("0x5FbDB2315678afecb367f032d93F642f64180aa3"),
L2GlobalExitRootManagerAddr: common.HexToAddress("0x0000000000000000000000000000000000000000"),
L2GlobalExitRootManagerPosition: 2,
L1ChainID: 1337,
L2DefaultChainID: 1000,
Balances: map[common.Address]*big.Int{
common.HexToAddress("0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266"): bigIntFromBase10String("1000000000000000000000"),
common.HexToAddress("0x70997970C51812dc3A010C7d01b50e0d17dc79C8"): bigIntFromBase10String("1000000000000000000000"),
Expand Down Expand Up @@ -214,6 +226,8 @@ func loadCustomNetworkConfig(ctx *cli.Context) (NetworkConfig, error) {
cfg.GenBlockNumber = cfgJSON.GenBlockNumber
cfg.PoEAddr = common.HexToAddress(cfgJSON.PoEAddr)
cfg.MaticAddr = common.HexToAddress(cfgJSON.MaticAddr)
cfg.L2GlobalExitRootManagerAddr = common.HexToAddress(cfgJSON.L2GlobalExitRootManagerAddr)
cfg.L2GlobalExitRootManagerPosition = cfgJSON.L2GlobalExitRootManagerPosition
cfg.L1ChainID = cfgJSON.L1ChainID
cfg.L2DefaultChainID = cfgJSON.L2DefaultChainID
cfg.Balances = make(map[common.Address]*big.Int, len(cfgJSON.Balances))
Expand Down
1 change: 1 addition & 0 deletions db/migrations/0001.sql
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ CREATE TABLE state.batch
matic_collateral NUMERIC(78,0),
chain_id BIGINT,
global_exit_root BYTEA,
rollup_exit_root BYTEA,

received_at TIMESTAMP WITH TIME ZONE NOT NULL,
consolidated_at TIMESTAMP WITH TIME ZONE
Expand Down
1 change: 1 addition & 0 deletions state/batch.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ type Batch struct {
ConsolidatedTxHash common.Hash
ChainID *big.Int
GlobalExitRoot common.Hash
RollupExitRoot common.Hash
Header *types.Header
Uncles []*types.Header
Transactions []*types.Transaction
Expand Down
8 changes: 8 additions & 0 deletions state/batchprocessor.go
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,14 @@ func (b *BasicBatchProcessor) commit(ctx context.Context, batch *Batch) error {
if b.stateRoot != nil {
root.SetBytes(b.stateRoot)
batch.Header.Root = root

// set local exit root
key := new(big.Int).SetUint64(b.State.cfg.L2GlobalExitRootManagerPosition)
localExitRoot, err := b.State.tree.GetStorageAt(ctx, b.State.cfg.L2GlobalExitRootManagerAddr, common.BigToHash(key), b.stateRoot)
if err != nil {
return err
}
batch.RollupExitRoot = common.BigToHash(localExitRoot)
}

err := b.State.AddBatch(ctx, batch)
Expand Down
6 changes: 6 additions & 0 deletions state/config.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
package state

import "github.com/ethereum/go-ethereum/common"

// Config is state config
type Config struct {
// DefaultChainID is the common ChainID to all the sequencers
DefaultChainID uint64
// MaxCumulativeGasUsed is the max gas allowed per batch
MaxCumulativeGasUsed uint64
// L2GlobalExitRootManagerAddr is the L2 address of the exit root manager SC
L2GlobalExitRootManagerAddr common.Address
// L2GlobalExitRootManagerPosition is the position inside SC's storage to read the new local state root
L2GlobalExitRootManagerPosition uint64
}
28 changes: 14 additions & 14 deletions state/pgstatestorage/pgstatestorage.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ const (
getBlockByHashSQL = "SELECT * FROM state.block WHERE block_hash = $1"
getBlockByNumberSQL = "SELECT * FROM state.block WHERE block_num = $1"
getLastBlockNumberSQL = "SELECT COALESCE(MAX(block_num), 0) FROM state.block"
getLastVirtualBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch ORDER BY batch_num DESC LIMIT 1"
getLastConsolidatedBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch WHERE consolidated_tx_hash != $1 ORDER BY batch_num DESC LIMIT 1"
getPreviousVirtualBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch ORDER BY batch_num DESC LIMIT 1 OFFSET $1"
getPreviousConsolidatedBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch WHERE consolidated_tx_hash != $1 ORDER BY batch_num DESC LIMIT 1 OFFSET $2"
getBatchByHashSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch WHERE batch_hash = $1"
getBatchByNumberSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root FROM state.batch WHERE batch_num = $1"
getLastVirtualBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch ORDER BY batch_num DESC LIMIT 1"
getLastConsolidatedBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch WHERE consolidated_tx_hash != $1 ORDER BY batch_num DESC LIMIT 1"
getPreviousVirtualBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch ORDER BY batch_num DESC LIMIT 1 OFFSET $1"
getPreviousConsolidatedBatchSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch WHERE consolidated_tx_hash != $1 ORDER BY batch_num DESC LIMIT 1 OFFSET $2"
getBatchByHashSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch WHERE batch_hash = $1"
getBatchByNumberSQL = "SELECT block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, consolidated_at, chain_id, global_exit_root, rollup_exit_root FROM state.batch WHERE batch_num = $1"
getLastVirtualBatchNumberSQL = "SELECT COALESCE(MAX(batch_num), 0) FROM state.batch"
getLastConsolidatedBatchNumberSQL = "SELECT COALESCE(MAX(batch_num), 0) FROM state.batch WHERE consolidated_tx_hash != $1"
getTransactionByHashSQL = "SELECT transaction.encoded FROM state.transaction WHERE hash = $1"
Expand All @@ -51,7 +51,7 @@ const (
getSequencerSQL = "SELECT * FROM state.sequencer WHERE address = $1"
getReceiptSQL = "SELECT * FROM state.receipt WHERE tx_hash = $1"
resetSQL = "DELETE FROM state.block WHERE block_num > $1"
addBatchSQL = "INSERT INTO state.batch (batch_num, batch_hash, block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, chain_id, global_exit_root) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13)"
addBatchSQL = "INSERT INTO state.batch (batch_num, batch_hash, block_num, sequencer, aggregator, consolidated_tx_hash, header, uncles, raw_txs_data, matic_collateral, received_at, chain_id, global_exit_root, rollup_exit_root) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14)"
addTransactionSQL = "INSERT INTO state.transaction (hash, from_address, encoded, decoded, batch_num, tx_index) VALUES($1, $2, $3, $4, $5, $6)"
addReceiptSQL = "INSERT INTO state.receipt (type, post_state, status, cumulative_gas_used, gas_used, batch_num, batch_hash, tx_hash, tx_index, tx_from, tx_to, contract_address) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12)"
addLogSQL = "INSERT INTO state.log (log_index, transaction_index, transaction_hash, batch_hash, batch_num, address, data, topic0, topic1, topic2, topic3) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11)"
Expand Down Expand Up @@ -212,12 +212,12 @@ func (s *PostgresStorage) GetLastBatch(ctx context.Context, isVirtual bool) (*st
err = s.queryRow(ctx, getLastVirtualBatchSQL).Scan(&batch.BlockNumber,
&batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash,
&batch.Header, &batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.RollupExitRoot)
} else {
err = s.queryRow(ctx, getLastConsolidatedBatchSQL, common.Hash{}).Scan(
&batch.BlockNumber, &batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash,
&batch.Header, &batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.RollupExitRoot)
}
batch.ChainID = new(big.Int).SetUint64(chain)

Expand Down Expand Up @@ -246,12 +246,12 @@ func (s *PostgresStorage) GetPreviousBatch(ctx context.Context, isVirtual bool,
err = s.queryRow(ctx, getPreviousVirtualBatchSQL, offset).Scan(
&batch.BlockNumber, &batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash,
&batch.Header, &batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.RollupExitRoot)
} else {
err = s.queryRow(ctx, getPreviousConsolidatedBatchSQL, common.Hash{}, offset).Scan(
&batch.BlockNumber, &batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash, &batch.Header,
&batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.RollupExitRoot)
}
batch.ChainID = new(big.Int).SetUint64(chain)

Expand All @@ -275,7 +275,7 @@ func (s *PostgresStorage) GetBatchByHash(ctx context.Context, hash common.Hash)
err := s.queryRow(ctx, getBatchByHashSQL, hash).Scan(
&batch.BlockNumber, &batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash,
&batch.Header, &batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.GlobalExitRoot)
if errors.Is(err, pgx.ErrNoRows) {
return nil, state.ErrNotFound
} else if err != nil {
Expand Down Expand Up @@ -691,7 +691,7 @@ func (s *PostgresStorage) GetLastBatchNumberConsolidatedOnEthereum(ctx context.C
// AddBatch adds a new batch to the State Store
func (s *PostgresStorage) AddBatch(ctx context.Context, batch *state.Batch) error {
_, err := s.exec(ctx, addBatchSQL, batch.Number().Uint64(), batch.Hash(), batch.BlockNumber, batch.Sequencer, batch.Aggregator,
batch.ConsolidatedTxHash, batch.Header, batch.Uncles, batch.RawTxsData, batch.MaticCollateral.String(), batch.ReceivedAt, batch.ChainID.String(), batch.GlobalExitRoot)
batch.ConsolidatedTxHash, batch.Header, batch.Uncles, batch.RawTxsData, batch.MaticCollateral.String(), batch.ReceivedAt, batch.ChainID.String(), batch.GlobalExitRoot, batch.RollupExitRoot)
return err
}

Expand Down Expand Up @@ -761,7 +761,7 @@ func (s *PostgresStorage) getBatchWithoutTxsByNumber(ctx context.Context, batchN
err := s.db.QueryRow(ctx, getBatchByNumberSQL, batchNumber).Scan(
&batch.BlockNumber, &batch.Sequencer, &batch.Aggregator, &batch.ConsolidatedTxHash,
&batch.Header, &batch.Uncles, &batch.RawTxsData, &maticCollateral,
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot)
&batch.ReceivedAt, &batch.ConsolidatedAt, &chain, &batch.GlobalExitRoot, &batch.RollupExitRoot)
if errors.Is(err, pgx.ErrNoRows) {
return nil, state.ErrNotFound
} else if err != nil {
Expand Down

0 comments on commit 4f31c2f

Please sign in to comment.