Skip to content

Commit 6db2912

Browse files
authored
Add support for Electra (#131)
1 parent cff9198 commit 6db2912

File tree

7 files changed

+166
-549
lines changed

7 files changed

+166
-549
lines changed

.github/workflows/checks.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Set up Go 1.x
15-
uses: actions/setup-go@v2
15+
uses: actions/setup-go@v5
1616
with:
17-
go-version: ^1.20
17+
go-version: ^1.24
1818
id: go
1919

2020
- name: Check out code into the Go module directory
21-
uses: actions/checkout@v2
21+
uses: actions/checkout@v4
2222

2323
- name: Run unit tests and generate the coverage report
2424
run: make test
@@ -28,22 +28,22 @@ jobs:
2828
runs-on: ubuntu-latest
2929
steps:
3030
- name: Set up Go 1.x
31-
uses: actions/setup-go@v2
31+
uses: actions/setup-go@v5
3232
with:
33-
go-version: ^1.20
33+
go-version: ^1.24
3434
id: go
3535

3636
- name: Check out code into the Go module directory
37-
uses: actions/checkout@v2
37+
uses: actions/checkout@v4
3838

3939
- name: Install gofumpt
40-
run: go install mvdan.cc/gofumpt@latest
40+
run: go install mvdan.cc/gofumpt@v0.7.0
4141

4242
- name: Install staticcheck
43-
run: go install honnef.co/go/tools/cmd/staticcheck@v0.4.3
43+
run: go install honnef.co/go/tools/cmd/staticcheck@v0.6.0
4444

4545
- name: Install golangci-lint
46-
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.51.2
46+
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.64.5
4747

4848
- name: Lint
4949
run: make lint
@@ -56,13 +56,13 @@ jobs:
5656
runs-on: ubuntu-latest
5757
steps:
5858
- name: Set up Go 1.x
59-
uses: actions/setup-go@v2
59+
uses: actions/setup-go@v5
6060
with:
61-
go-version: ^1.20
61+
go-version: ^1.24
6262
id: go
6363

6464
- name: Check out code into the Go module directory
65-
uses: actions/checkout@v2
65+
uses: actions/checkout@v4
6666

6767
- name: Fuzz each test for one second
6868
run: TERM=xterm FUZZTIME=1s make fuzz

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Checkout sources
13-
uses: actions/checkout@v2
13+
uses: actions/checkout@v4
1414

1515
- name: Create release
1616
id: create_release

.golangci.yaml

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
linters:
22
enable-all: true
33
disable:
4+
- depguard
45
- dupl
56
- exhaustruct
67
- funlen
@@ -9,13 +10,18 @@ linters:
910
- gocritic
1011
- godot
1112
- godox
12-
- gomnd
13+
- inamedparam
14+
- intrange
1315
- lll
16+
- mnd
1417
- musttag
1518
- nlreturn
1619
- nonamedreturns
17-
- nosnakecase
1820
- paralleltest
21+
- perfsprint
22+
- revive
23+
- tenv
24+
- testifylint
1925
- testpackage
2026
- varnamelen
2127
- wrapcheck
@@ -27,25 +33,18 @@ linters:
2733
- contextcheck
2834
- rowserrcheck
2935
- sqlclosecheck
30-
- structcheck
3136
- wastedassign
3237

33-
#
34-
# Disabled because deprecated:
35-
#
36-
- deadcode
37-
- exhaustivestruct
38-
- golint
39-
- ifshort
40-
- interfacer
41-
- maligned
42-
- scopelint
43-
- varcheck
44-
4538
linters-settings:
39+
cyclop:
40+
max-complexity: 20
4641
tagliatelle:
4742
case:
4843
rules:
4944
json: snake
5045
gofumpt:
5146
extra-rules: true
47+
gomoddirectives:
48+
replace-allow-list:
49+
- github.com/attestantio/go-builder-client
50+
- github.com/attestantio/go-eth2-client

Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,15 @@ lint:
2828
staticcheck ./...
2929
golangci-lint run
3030

31+
gofumpt:
32+
gofumpt -l -w -extra .
33+
34+
fmt:
35+
gofmt -s -w .
36+
gofumpt -extra -w .
37+
gci write .
38+
go mod tidy
39+
3140
cover:
3241
go test -coverprofile=/tmp/go-sim-lb.cover.tmp ./...
3342
go tool cover -func /tmp/go-sim-lb.cover.tmp

go.mod

Lines changed: 31 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,78 +1,50 @@
11
module github.com/flashbots/go-boost-utils
22

3-
go 1.20
3+
go 1.24
44

55
require (
6-
github.com/attestantio/go-builder-client v0.4.2
7-
github.com/attestantio/go-eth2-client v0.19.8
8-
github.com/consensys/gnark-crypto v0.12.1
9-
github.com/ethereum/go-ethereum v1.13.14
10-
github.com/stretchr/testify v1.8.4
11-
github.com/trailofbits/go-fuzz-utils v0.0.0-20210901195358-9657fcfd256c
6+
github.com/attestantio/go-builder-client v0.6.1
7+
github.com/attestantio/go-eth2-client v0.24.0
8+
github.com/consensys/gnark-crypto v0.16.0
9+
github.com/ethereum/go-ethereum v1.15.2
10+
github.com/stretchr/testify v1.10.0
11+
github.com/trailofbits/go-fuzz-utils v0.0.0-20240830175354-474de707d2aa
1212
)
1313

1414
require (
15-
github.com/DataDog/zstd v1.5.2 // indirect
16-
github.com/StackExchange/wmi v1.2.1 // indirect
17-
github.com/beorn7/perks v1.0.1 // indirect
18-
github.com/bits-and-blooms/bitset v1.10.0 // indirect
19-
github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect
20-
github.com/cespare/xxhash/v2 v2.2.0 // indirect
21-
github.com/cockroachdb/errors v1.9.1 // indirect
22-
github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect
23-
github.com/cockroachdb/pebble v0.0.0-20230928194634-aa077af62593 // indirect
24-
github.com/cockroachdb/redact v1.1.3 // indirect
25-
github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect
26-
github.com/consensys/bavard v0.1.13 // indirect
27-
github.com/crate-crypto/go-ipa v0.0.0-20231025140028-3c0104f4b233 // indirect
28-
github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect
15+
github.com/bits-and-blooms/bitset v1.20.0 // indirect
16+
github.com/consensys/bavard v0.1.29 // indirect
17+
github.com/crate-crypto/go-ipa v0.0.0-20240724233137-53bbb0ceb27a // indirect
18+
github.com/crate-crypto/go-kzg-4844 v1.1.0 // indirect
2919
github.com/davecgh/go-spew v1.1.1 // indirect
30-
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect
31-
github.com/ethereum/c-kzg-4844 v0.4.0 // indirect
32-
github.com/fatih/color v1.15.0 // indirect
33-
github.com/ferranbt/fastssz v0.1.3 // indirect
34-
github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 // indirect
35-
github.com/getsentry/sentry-go v0.18.0 // indirect
20+
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.4.0 // indirect
21+
github.com/emicklei/dot v1.6.4 // indirect
22+
github.com/ethereum/c-kzg-4844 v1.0.3 // indirect
23+
github.com/ethereum/go-verkle v0.2.2 // indirect
24+
github.com/ferranbt/fastssz v0.1.4 // indirect
3625
github.com/go-ole/go-ole v1.3.0 // indirect
37-
github.com/goccy/go-yaml v1.11.2 // indirect
38-
github.com/gofrs/flock v0.8.1 // indirect
39-
github.com/gogo/protobuf v1.3.2 // indirect
40-
github.com/golang/protobuf v1.5.3 // indirect
26+
github.com/goccy/go-yaml v1.15.23 // indirect
27+
github.com/gofrs/flock v0.12.1 // indirect
4128
github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb // indirect
42-
github.com/holiman/uint256 v1.2.4 // indirect
43-
github.com/klauspost/compress v1.15.15 // indirect
44-
github.com/klauspost/cpuid/v2 v2.2.5 // indirect
45-
github.com/kr/pretty v0.3.1 // indirect
46-
github.com/kr/text v0.2.0 // indirect
47-
github.com/mattn/go-colorable v0.1.13 // indirect
48-
github.com/mattn/go-isatty v0.0.20 // indirect
49-
github.com/mattn/go-runewidth v0.0.13 // indirect
50-
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
29+
github.com/holiman/uint256 v1.3.2 // indirect
30+
github.com/klauspost/cpuid/v2 v2.2.9 // indirect
31+
github.com/mattn/go-runewidth v0.0.16 // indirect
5132
github.com/minio/sha256-simd v1.0.1 // indirect
5233
github.com/mitchellh/mapstructure v1.5.0 // indirect
5334
github.com/mmcloughlin/addchain v0.4.0 // indirect
5435
github.com/olekukonko/tablewriter v0.0.5 // indirect
5536
github.com/pkg/errors v0.9.1 // indirect
5637
github.com/pmezard/go-difflib v1.0.0 // indirect
57-
github.com/prometheus/client_golang v1.16.0 // indirect
58-
github.com/prometheus/client_model v0.3.0 // indirect
59-
github.com/prometheus/common v0.42.0 // indirect
60-
github.com/prometheus/procfs v0.10.1 // indirect
61-
github.com/prysmaticlabs/go-bitfield v0.0.0-20210809151128-385d8c5e3fb7 // indirect
62-
github.com/rivo/uniseg v0.2.0 // indirect
63-
github.com/rogpeppe/go-internal v1.11.0 // indirect
64-
github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect
65-
github.com/supranational/blst v0.3.11 // indirect
66-
github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect
67-
github.com/tklauser/go-sysconf v0.3.12 // indirect
68-
github.com/tklauser/numcpus v0.6.1 // indirect
69-
golang.org/x/crypto v0.17.0 // indirect
70-
golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa // indirect
71-
golang.org/x/sync v0.5.0 // indirect
72-
golang.org/x/sys v0.16.0 // indirect
73-
golang.org/x/text v0.14.0 // indirect
74-
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
75-
google.golang.org/protobuf v1.30.0 // indirect
38+
github.com/prysmaticlabs/go-bitfield v0.0.0-20240618144021-706c95b2dd15 // indirect
39+
github.com/rivo/uniseg v0.4.7 // indirect
40+
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
41+
github.com/supranational/blst v0.3.14 // indirect
42+
github.com/tklauser/go-sysconf v0.3.14 // indirect
43+
github.com/tklauser/numcpus v0.9.0 // indirect
44+
github.com/yusufpapurcu/wmi v1.2.4 // indirect
45+
golang.org/x/crypto v0.33.0 // indirect
46+
golang.org/x/sync v0.11.0 // indirect
47+
golang.org/x/sys v0.30.0 // indirect
7648
gopkg.in/yaml.v2 v2.4.0 // indirect
7749
gopkg.in/yaml.v3 v3.0.1 // indirect
7850
rsc.io/tmplfunc v0.0.3 // indirect

0 commit comments

Comments
 (0)