Skip to content

Commit

Permalink
[R4R]: V1 to v2 debug (#1394)
Browse files Browse the repository at this point in the history
# Goals of PR

Core changes:
* fix gaslimit upgrade bug

Notes:
no

Related Issues:
no
  • Loading branch information
Sha3nS committed Jan 3, 2024
2 parents a18ec93 + 2c6dca9 commit dc93f2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion l2geth/consensus/clique/clique.go
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ func (c *Clique) FinalizeAndAssemble(chain consensus.ChainReader, header *types.
//if UpdateGasLimitBlock = 0, from the genesis block
//if UpdateGasLimitBlock = x, from the x
mantleUpgradeConfig := upgrade.NewMantleUpgradeConfig(chain.Config().ChainID)
if !mantleUpgradeConfig.IsUpdateGasLimitBlock(header.Number) && chain.Config().ChainID == params.MantleTestnetChainID {
if !mantleUpgradeConfig.IsUpdateGasLimitBlock(header.Number) && chain.Config().ChainID.Cmp(params.MantleTestnetChainID) == 0 {
//for testnet, when the UpdateGasLimitBlock is actived, we must update the gaslimit for all of block
//which is after the "updategaslimit" block
header.GasLimit = uint64(upgrade.PreUpgradedGaslimit)
Expand Down

0 comments on commit dc93f2a

Please sign in to comment.