Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update l1 update gas
Browse files Browse the repository at this point in the history
alexisdevilliers committed Dec 31, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 03f4e46 commit 39ff3a2
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion common/version/version.go
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@ import (
"runtime/debug"
)

var tag = "v4.4.84"
var tag = "v4.4.85"

var commit = func() string {
if info, ok := debug.ReadBuildInfo(); ok {
4 changes: 2 additions & 2 deletions rollup/internal/controller/relayer/l1_relayer.go
Original file line number Diff line number Diff line change
@@ -251,14 +251,14 @@ func (r *Layer1Relayer) shouldUpdateGasOracle(baseFee uint64, blobBaseFee uint64
}

expectedBaseFeeDelta := r.lastBaseFee*r.gasPriceDiff/gasPriceDiffPrecision + 1
if baseFee >= r.minGasPrice && (baseFee >= r.lastBaseFee+expectedBaseFeeDelta || baseFee+expectedBaseFeeDelta <= r.lastBaseFee) {
if baseFee >= r.minGasPrice && math.Abs(float64(baseFee-r.lastBaseFee)) >= float64(expectedBaseFeeDelta) {
return true
}

expectedBlobBaseFeeDelta := r.lastBlobBaseFee * r.gasPriceDiff / gasPriceDiffPrecision
// Plus a minimum of 0.01 gwei, since the blob base fee is usually low, preventing short-time flunctuation.
expectedBlobBaseFeeDelta += 10000000
if blobBaseFee >= r.minGasPrice && (blobBaseFee >= r.lastBlobBaseFee+expectedBlobBaseFeeDelta || blobBaseFee+expectedBlobBaseFeeDelta <= r.lastBlobBaseFee) {
if blobBaseFee >= r.minGasPrice && math.Abs(float64(blobBaseFee-r.lastBlobBaseFee)) >= float64(expectedBlobBaseFeeDelta) {
return true
}

0 comments on commit 39ff3a2

Please sign in to comment.