Skip to content

Commit

Permalink
Fix data poster noop storage check in batch poster
Browse files Browse the repository at this point in the history
  • Loading branch information
PlasmaPower committed Apr 9, 2024
1 parent 4ac357c commit 3abce87
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion arbnode/batch_poster.go
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ func (b *BatchPoster) checkReverts(ctx context.Context, to int64) (bool, error)
return false, fmt.Errorf("getting a receipt for transaction: %v, %w", tx.Hash, err)
}
if r.Status == types.ReceiptStatusFailed {
shouldHalt := !b.config().DataPoster.UseNoOpStorage
shouldHalt := !b.dataPoster.UsingNoOpStorage()
logLevel := log.Warn
if shouldHalt {
logLevel = log.Error
Expand Down
4 changes: 4 additions & 0 deletions arbnode/dataposter/data_poster.go
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,10 @@ func (p *DataPoster) MaxMempoolTransactions() uint64 {
return arbmath.MinInt(config.MaxMempoolTransactions, config.MaxMempoolWeight)
}

func (p *DataPoster) UsingNoOpStorage() bool {
return p.usingNoOpStorage
}

var ErrExceedsMaxMempoolSize = errors.New("posting this transaction will exceed max mempool size")

// Does basic check whether posting transaction with specified nonce would
Expand Down

0 comments on commit 3abce87

Please sign in to comment.