Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion simulators/eth2/common/builder/builder.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package builder

import (
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
beacon "github.com/protolambda/zrnt/eth2/beacon/common"
)

Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/builder/mock/mock_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"time"

el_common "github.com/ethereum/go-ethereum/common"
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/hive/simulators/eth2/common/builder/types/bellatrix"
"github.com/ethereum/hive/simulators/eth2/common/builder/types/capella"
Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/builder/mock/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"math/big"
"net"

api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
beacon "github.com/protolambda/zrnt/eth2/beacon/common"
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"math/big"

el_common "github.com/ethereum/go-ethereum/common"
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
"github.com/ethereum/hive/simulators/eth2/common/builder/types/common"
blsu "github.com/protolambda/bls12-381-util"
"github.com/protolambda/zrnt/eth2/beacon/bellatrix"
Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/builder/types/capella/capella.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"math/big"

el_common "github.com/ethereum/go-ethereum/common"
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
"github.com/ethereum/hive/simulators/eth2/common/builder/types/common"
blsu "github.com/protolambda/bls12-381-util"
"github.com/protolambda/zrnt/eth2/beacon/capella"
Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/builder/types/common/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"math/big"

el_common "github.com/ethereum/go-ethereum/common"
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
blsu "github.com/protolambda/bls12-381-util"
"github.com/protolambda/zrnt/eth2/beacon/common"
beacon "github.com/protolambda/zrnt/eth2/beacon/common"
Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/clients/beacon.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"time"

ethcommon "github.com/ethereum/go-ethereum/common"
api "github.com/ethereum/go-ethereum/core/beacon"
api "github.com/ethereum/go-ethereum/beacon/engine"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/hive/hivesim"

Expand Down
2 changes: 1 addition & 1 deletion simulators/eth2/common/clients/execution.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ import (
"strings"
"time"

api "github.com/ethereum/go-ethereum/beacon/engine"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
api "github.com/ethereum/go-ethereum/core/beacon"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/ethclient"
"github.com/ethereum/go-ethereum/rpc"
Expand Down
18 changes: 6 additions & 12 deletions simulators/eth2/common/config/execution/execution_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -279,11 +279,10 @@ func (conf *ExecutionGenesis) ToParams(
depositAddress [20]byte,
) hivesim.Params {
params := hivesim.Params{
"HIVE_DEPOSIT_CONTRACT_ADDRESS": common.Address(depositAddress).
String(),
"HIVE_NETWORK_ID": fmt.Sprintf("%d", conf.NetworkID),
"HIVE_CHAIN_ID": conf.Genesis.Config.ChainID.String(),
"HIVE_FORK_HOMESTEAD": conf.Genesis.Config.HomesteadBlock.String(),
"HIVE_DEPOSIT_CONTRACT_ADDRESS": common.Address(depositAddress).String(),
"HIVE_NETWORK_ID": fmt.Sprintf("%d", conf.NetworkID),
"HIVE_CHAIN_ID": conf.Genesis.Config.ChainID.String(),
"HIVE_FORK_HOMESTEAD": conf.Genesis.Config.HomesteadBlock.String(),
//"HIVE_FORK_DAO_BLOCK": conf.Genesis.Config.DAOForkBlock.String(), // nil error, not used anyway
"HIVE_FORK_TANGERINE": conf.Genesis.Config.EIP150Block.String(),
"HIVE_FORK_SPURIOUS": conf.Genesis.Config.EIP155Block.String(), // also eip558
Expand All @@ -299,15 +298,10 @@ func (conf *ExecutionGenesis) ToParams(
"HIVE_TERMINAL_TOTAL_DIFFICULTY": conf.Genesis.Config.TerminalTotalDifficulty.String(),
}
if conf.Genesis.Config.ShanghaiTime != nil {
params = params.Set(
"HIVE_SHANGHAI_TIMESTAMP",
conf.Genesis.Config.ShanghaiTime.String(),
)
params["HIVE_SHANGHAI_TIMESTAMP"] = fmt.Sprint(*conf.Genesis.Config.ShanghaiTime)
}
if conf.Genesis.Config.Clique != nil {
params["HIVE_CLIQUE_PERIOD"] = fmt.Sprint(
conf.Genesis.Config.Clique.Period,
)
params["HIVE_CLIQUE_PERIOD"] = fmt.Sprint(conf.Genesis.Config.Clique.Period)
}
return params
}
Expand Down
38 changes: 30 additions & 8 deletions simulators/eth2/common/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ module github.com/ethereum/hive/simulators/eth2/common
go 1.18

require (
github.com/ethereum/go-ethereum v1.10.26
github.com/ethereum/hive v0.0.0-20221214152536-bfabd993ae7b
github.com/ethereum/go-ethereum v1.11.4
github.com/ethereum/hive v0.0.0-20230313141339-8e3200bfc09e
github.com/golang-jwt/jwt/v4 v4.3.0
github.com/google/uuid v1.3.0
github.com/gorilla/mux v1.8.0
Expand All @@ -20,35 +20,57 @@ require (
github.com/sirupsen/logrus v1.9.0
github.com/tyler-smith/go-bip39 v1.1.0
github.com/wealdtech/go-eth2-util v1.8.0
golang.org/x/exp v0.0.0-20230108222341-4b8118a2686a
golang.org/x/exp v0.0.0-20230206171751-46f607a40771
gopkg.in/yaml.v2 v2.4.0
)

require (
github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 // indirect
github.com/Microsoft/go-winio v0.5.2 // indirect
github.com/Microsoft/hcsshim v0.9.6 // indirect
github.com/VictoriaMetrics/fastcache v1.12.0 // indirect
github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/containerd/cgroups v1.0.4 // indirect
github.com/containerd/containerd v1.6.18 // indirect
github.com/deckarep/golang-set/v2 v2.1.0 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect
github.com/docker/docker v20.10.17+incompatible // indirect
github.com/docker/go-connections v0.4.0 // indirect
github.com/docker/go-units v0.4.0 // indirect
github.com/edsrzf/mmap-go v1.1.0 // indirect
github.com/ethereum/hive/hiveproxy v0.0.0-20230313101845-c7dfe88c8138 // indirect
github.com/ferranbt/fastssz v0.1.2 // indirect
github.com/fsouza/go-dockerclient v1.8.1 // indirect
github.com/go-kit/kit v0.12.0 // indirect
github.com/go-ole/go-ole v1.2.6 // indirect
github.com/go-stack/stack v1.8.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/snappy v0.0.4 // indirect
github.com/gorilla/websocket v1.5.0 // indirect
github.com/hashicorp/yamux v0.1.1 // indirect
github.com/holiman/big v0.0.0-20221017200358-a027dc42d04e // indirect
github.com/holiman/bloomfilter/v2 v2.0.3 // indirect
github.com/julienschmidt/httprouter v1.3.0 // indirect
github.com/kilic/bls12-381 v0.1.0 // indirect
github.com/klauspost/cpuid/v2 v2.2.2 // 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.14 // indirect
github.com/minio/sha256-simd v1.0.0 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/moby/sys/mount v0.3.3 // indirect
github.com/moby/sys/mountinfo v0.6.2 // indirect
github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6 // indirect
github.com/morikuni/aec v1.0.0 // indirect
github.com/olekukonko/tablewriter v0.0.5 // indirect
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.0.3-0.20211202183452-c5a74bcca799 // indirect
github.com/opencontainers/runc v1.1.2 // indirect
github.com/prometheus/tsdb v0.10.0 // indirect
github.com/rivo/uniseg v0.4.3 // indirect
github.com/rogpeppe/go-internal v1.8.1 // indirect
github.com/rogpeppe/go-internal v1.9.0 // indirect
github.com/rs/cors v1.8.2 // indirect
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a // indirect
Expand All @@ -57,15 +79,15 @@ require (
github.com/wealdtech/go-bytesutil v1.2.0 // indirect
github.com/wealdtech/go-eth2-types/v2 v2.8.0 // indirect
github.com/yusufpapurcu/wmi v1.2.2 // indirect
go.opencensus.io v0.23.0 // indirect
golang.org/x/crypto v0.4.0 // indirect
golang.org/x/sys v0.3.0 // indirect
golang.org/x/text v0.5.0 // indirect
golang.org/x/sys v0.5.0 // indirect
golang.org/x/text v0.7.0 // indirect
gopkg.in/inconshreveable/log15.v2 v2.0.0-20200109203555-b30bc20e4fd1 // indirect
gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

replace github.com/rauljordan/engine-proxy => github.com/marioevz/engine-proxy v0.0.0-20220617181151-e8661eb39eea

replace github.com/ethereum/go-ethereum v1.10.26 => github.com/lightclient/go-ethereum v1.10.10-0.20230116085521-6ab6d738866f

replace github.com/protolambda/eth2api => github.com/marioevz/eth2api v0.0.0-20230214151319-641a58f39ae4
Loading