refactor(config): moved fee vault addr to rollup config (#341)

* moved fee vault addr to rollup config

* fixed linter issue

* added back FeeVaultAddress

---------

Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
This commit is contained in:
Richord 2023-05-22 07:37:27 -07:00 committed by GitHub
parent a89ab83089
commit 2f7085715b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 2 deletions

View file

@ -24,6 +24,7 @@ import (
"golang.org/x/crypto/sha3" "golang.org/x/crypto/sha3"
"github.com/scroll-tech/go-ethereum/common" "github.com/scroll-tech/go-ethereum/common"
"github.com/scroll-tech/go-ethereum/rollup/rcfg"
) )
// Genesis hashes to enforce below configs on. // Genesis hashes to enforce below configs on.
@ -255,7 +256,6 @@ var (
} }
// ScrollAlphaChainConfig contains the chain parameters to run a node on the Scroll Alpha test network. // ScrollAlphaChainConfig contains the chain parameters to run a node on the Scroll Alpha test network.
ScrollFeeVaultAddress = common.HexToAddress("0x5300000000000000000000000000000000000005")
ScrollMaxTxPerBlock = 44 ScrollMaxTxPerBlock = 44
ScrollMaxTxPayloadBytesPerBlock = 120 * 1024 ScrollMaxTxPayloadBytesPerBlock = 120 * 1024
@ -285,7 +285,7 @@ var (
UseZktrie: true, UseZktrie: true,
MaxTxPerBlock: &ScrollMaxTxPerBlock, MaxTxPerBlock: &ScrollMaxTxPerBlock,
MaxTxPayloadBytesPerBlock: &ScrollMaxTxPayloadBytesPerBlock, MaxTxPayloadBytesPerBlock: &ScrollMaxTxPayloadBytesPerBlock,
FeeVaultAddress: &ScrollFeeVaultAddress, FeeVaultAddress: &rcfg.ScrollFeeVaultAddress,
EnableEIP2718: false, EnableEIP2718: false,
EnableEIP1559: false, EnableEIP1559: false,
}, },

View file

@ -16,6 +16,11 @@ var (
L2MessageQueueAddress = common.HexToAddress("0x5300000000000000000000000000000000000000") L2MessageQueueAddress = common.HexToAddress("0x5300000000000000000000000000000000000000")
WithdrawTrieRootSlot = common.BigToHash(big.NewInt(0)) WithdrawTrieRootSlot = common.BigToHash(big.NewInt(0))
// ScrollFeeVaultAddress is the address of the L2TxFeeVault
// predeploy
// see scroll-tech/scroll/contracts/src/L2/predeploys/L2TxFeeVault.sol
ScrollFeeVaultAddress = common.HexToAddress("0x5300000000000000000000000000000000000005")
// L1GasPriceOracleAddress is the address of the L1GasPriceOracle // L1GasPriceOracleAddress is the address of the L1GasPriceOracle
// predeploy // predeploy
// see scroll-tech/scroll/contracts/src/L2/predeploys/L1GasPriceOracle.sol // see scroll-tech/scroll/contracts/src/L2/predeploys/L1GasPriceOracle.sol