Skip to content

Commit

Permalink
Merge branch 'feature/fraud-proof' into Release/v0.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Sha3nS committed Apr 18, 2023
2 parents 7bf5a0e + ef5d4d1 commit 3e2b6db
Show file tree
Hide file tree
Showing 52 changed files with 3,356 additions and 3,172 deletions.
7 changes: 6 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog
## [0.3.1] - 2023-04-13
## [0.3.2] - 2023-04-18

### Features
- Reduce the amount of data sent to Layer1 rollup using EigenLayer, significantly lowering gas fees for Layer2([#811](https://github.com/mantlenetworkio/mantle/pull/811))

## [0.3.1](https://github.com/mantlenetworkio/mantle/commits/v0.3.1) - 2023-04-13

### Features
- Changed the rollup method from Layer1 CTC contract to EigenDA([#779](https://github.com/mantlenetworkio/mantle/pull/779))
Expand Down
822 changes: 822 additions & 0 deletions gas-oracle/bindings/bvm_eigen_datalayr_fee.go

Large diffs are not rendered by default.

639 changes: 614 additions & 25 deletions gas-oracle/bindings/gaspriceoracle.go

Large diffs are not rendered by default.

27 changes: 27 additions & 0 deletions gas-oracle/flags/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ var (
Value: "0x420000000000000000000000000000000000000F",
EnvVar: "GAS_PRICE_ORACLE_GAS_PRICE_ORACLE_ADDRESS",
}
DaFeeContractAddressFlag = cli.StringFlag{
Name: "da-fee-contract-address",
Usage: "Address of DA-Fee-Contract",
Value: "0x9109811E8eEe02520219612bB5D47C60c382F4aa",
EnvVar: "GAS_PRICE_ORACLE_DA_FEE_CONTRACT_ADDRESS",
}
PrivateKeyFlag = cli.StringFlag{
Name: "private-key",
Usage: "Private Key corresponding to BVM_GasPriceOracle Owner",
Expand All @@ -53,6 +59,11 @@ var (
Usage: "Enable updating the L2 gas price",
EnvVar: "GAS_PRICE_ORACLE_ENABLE_L2_GAS_PRICE",
}
EnableDaFeeFlag = cli.BoolFlag{
Name: "enable-da-gas-price",
Usage: "Enable updating the da gas price",
EnvVar: "GAS_PRICE_ORACLE_ENABLE_DA_FEE",
}
LogLevelFlag = cli.IntFlag{
Name: "loglevel",
Value: 3,
Expand Down Expand Up @@ -95,12 +106,24 @@ var (
Usage: "polling time for updating the L1 base fee",
EnvVar: "GAS_PRICE_ORACLE_L1_BASE_FEE_EPOCH_LENGTH_SECONDS",
}
DaFeeEpochLengthSecondsFlag = cli.Uint64Flag{
Name: "da-fee-epoch-length-seconds",
Value: 15,
Usage: "polling time for updating the Da fee",
EnvVar: "GAS_PRICE_ORACLE_DA_FEE_EPOCH_LENGTH_SECONDS",
}
L1BaseFeeSignificanceFactorFlag = cli.Float64Flag{
Name: "l1-base-fee-significant-factor",
Value: 0.10,
Usage: "only update when the L1 base fee changes by more than this factor",
EnvVar: "GAS_PRICE_ORACLE_L1_BASE_FEE_SIGNIFICANT_FACTOR",
}
DaFeeSignificanceFactorFlag = cli.Float64Flag{
Name: "da-fee-significant-factor",
Value: 0.10,
Usage: "only update when the L1 base fee changes by more than this factor",
EnvVar: "GAS_PRICE_ORACLE_DA_FEE_SIGNIFICANT_FACTOR",
}
L2GasPriceSignificanceFactorFlag = cli.Float64Flag{
Name: "significant-factor",
Value: 0.05,
Expand Down Expand Up @@ -178,7 +201,9 @@ var Flags = []cli.Flag{
L1ChainIDFlag,
L2ChainIDFlag,
L1BaseFeeSignificanceFactorFlag,
DaFeeSignificanceFactorFlag,
GasPriceOracleAddressFlag,
DaFeeContractAddressFlag,
PrivateKeyFlag,
TransactionGasPriceFlag,
LogLevelFlag,
Expand All @@ -188,12 +213,14 @@ var Flags = []cli.Flag{
AverageBlockGasLimitPerEpochFlag,
EpochLengthSecondsFlag,
L1BaseFeeEpochLengthSecondsFlag,
DaFeeEpochLengthSecondsFlag,
L2GasPriceSignificanceFactorFlag,
BybitBackendURL,
TokenPricerUpdateFrequencySecond,
WaitForReceiptFlag,
EnableL1BaseFeeFlag,
EnableL2GasPriceFlag,
EnableDaFeeFlag,
MetricsEnabledFlag,
MetricsHTTPFlag,
MetricsPortFlag,
Expand Down
47 changes: 27 additions & 20 deletions gas-oracle/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,50 +3,54 @@ module github.com/mantlenetworkio/mantle/gas-oracle
go 1.18

require (
github.com/ethereum/go-ethereum v1.10.17
github.com/urfave/cli v1.22.5
github.com/ethereum/go-ethereum v1.10.26
github.com/go-resty/resty/v2 v2.7.0
github.com/stretchr/testify v1.8.1
github.com/urfave/cli v1.22.12
)

require (
github.com/VictoriaMetrics/fastcache v1.9.0 // indirect
github.com/allegro/bigcache v1.2.1 // indirect
github.com/btcsuite/btcd v0.22.0-beta // indirect
github.com/btcsuite/btcd/btcec/v2 v2.1.2 // indirect
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.1 // indirect
github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/deckarep/golang-set v1.8.0 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect
github.com/deepmap/oapi-codegen v1.8.2 // indirect
github.com/edsrzf/mmap-go v1.1.0 // indirect
github.com/fjl/memsize v0.0.1 // indirect
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 // indirect
github.com/go-kit/kit v0.10.0 // indirect
github.com/go-kit/kit v0.12.0 // indirect
github.com/go-ole/go-ole v1.2.6 // indirect
github.com/go-resty/resty/v2 v2.7.0 // indirect
github.com/go-stack/stack v1.8.1 // indirect
github.com/golang/snappy v0.0.4 // indirect
github.com/google/go-cmp v0.5.8 // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/gorilla/websocket v1.5.0 // indirect
github.com/hashicorp/go-bexpr v0.1.11 // indirect
github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect
github.com/holiman/bloomfilter/v2 v2.0.3 // indirect
github.com/holiman/uint256 v1.2.0 // indirect
github.com/huin/goupnp v1.0.3 // indirect
github.com/influxdata/influxdb v1.8.3 // indirect
github.com/influxdata/influxdb-client-go/v2 v2.4.0 // indirect
github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097 // indirect
github.com/mattn/go-colorable v0.1.12 // indirect
github.com/mattn/go-isatty v0.0.14 // indirect
github.com/kr/pretty v0.3.0 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.16 // indirect
github.com/mattn/go-runewidth v0.0.13 // indirect
github.com/mitchellh/mapstructure v1.4.3 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/olekukonko/tablewriter v0.0.5 // indirect
github.com/onsi/ginkgo v1.16.4 // indirect
github.com/onsi/gomega v1.16.0 // indirect
github.com/onsi/ginkgo v1.16.5 // indirect
github.com/onsi/gomega v1.24.0 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/tsdb v0.10.0 // indirect
github.com/rivo/uniseg v0.2.0 // indirect
github.com/rjeczalik/notify v0.9.2 // indirect
github.com/rogpeppe/go-internal v1.8.1 // indirect
github.com/rs/cors v1.8.2 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
Expand All @@ -56,10 +60,13 @@ require (
github.com/tklauser/numcpus v0.4.0 // indirect
github.com/tyler-smith/go-bip39 v1.1.0 // indirect
github.com/yusufpapurcu/wmi v1.2.2 // indirect
golang.org/x/crypto v0.0.0-20220307211146-efcb8507fb70 // indirect
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2 // indirect
golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5 // indirect
golang.org/x/time v0.0.0-20220224211638-0e9765cccd65 // indirect
golang.org/x/crypto v0.3.0 // indirect
golang.org/x/net v0.3.0 // indirect
golang.org/x/sync v0.1.0 // indirect
golang.org/x/sys v0.3.0 // indirect
golang.org/x/time v0.0.0-20220922220347-f3bd1da661af // indirect
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Loading

0 comments on commit 3e2b6db

Please sign in to comment.