Skip to content

Commit

Permalink
Merge pull request #788 from OffchainLabs/panic-on-compress-failure
Browse files Browse the repository at this point in the history
Panic if tx compression fails in PosterDataCost
  • Loading branch information
PlasmaPower authored Jul 13, 2022
2 parents f97f49c + 12a4442 commit 9bdfeaf
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions arbos/l1pricing/l1pricing.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import (
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/log"
"github.com/offchainlabs/nitro/arbos/storage"
"github.com/offchainlabs/nitro/arbos/util"
)
Expand Down Expand Up @@ -622,8 +621,7 @@ func (ps *L1PricingState) PosterDataCost(message core.Message, poster common.Add

byteCount, err := byteCountAfterBrotli0(message.Data())
if err != nil {
log.Error("failed to compress tx", "err", err)
return common.Big0, 0
panic(fmt.Sprintf("failed to compress tx: %v", err))
}

// Approximate the l1 fee charged for posting this tx's calldata
Expand Down

0 comments on commit 9bdfeaf

Please sign in to comment.