Commit c53062fa authored by Joshua Gutow's avatar Joshua Gutow

Fix lint in op-e2e

parent 70865c56
...@@ -94,7 +94,7 @@ func (ea *L2EngineAPI) startBlock(parent common.Hash, params *eth.PayloadAttribu ...@@ -94,7 +94,7 @@ func (ea *L2EngineAPI) startBlock(parent common.Hash, params *eth.PayloadAttribu
for i, otx := range params.Transactions { for i, otx := range params.Transactions {
var tx types.Transaction var tx types.Transaction
if err := tx.UnmarshalBinary(otx); err != nil { if err := tx.UnmarshalBinary(otx); err != nil {
return fmt.Errorf("transaction %d is not valid: %v", i, err) return fmt.Errorf("transaction %d is not valid: %w", i, err)
} }
ea.l2BuildingState.Prepare(tx.Hash(), i) ea.l2BuildingState.Prepare(tx.Hash(), i)
receipt, err := core.ApplyTransaction(ea.l2Cfg.Config, ea.l2Chain, &ea.l2BuildingHeader.Coinbase, receipt, err := core.ApplyTransaction(ea.l2Cfg.Config, ea.l2Chain, &ea.l2BuildingHeader.Coinbase,
...@@ -123,10 +123,10 @@ func (ea *L2EngineAPI) endBlock() (*types.Block, error) { ...@@ -123,10 +123,10 @@ func (ea *L2EngineAPI) endBlock() (*types.Block, error) {
// Write state changes to db // Write state changes to db
root, err := ea.l2BuildingState.Commit(ea.l2Cfg.Config.IsEIP158(header.Number)) root, err := ea.l2BuildingState.Commit(ea.l2Cfg.Config.IsEIP158(header.Number))
if err != nil { if err != nil {
return nil, fmt.Errorf("l2 state write error: %v", err) return nil, fmt.Errorf("l2 state write error: %w", err)
} }
if err := ea.l2BuildingState.Database().TrieDB().Commit(root, false, nil); err != nil { if err := ea.l2BuildingState.Database().TrieDB().Commit(root, false, nil); err != nil {
return nil, fmt.Errorf("l2 trie write error: %v", err) return nil, fmt.Errorf("l2 trie write error: %w", err)
} }
return block, nil return block, nil
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment