Skip to content

Commit 7f5c089

Browse files
authored
Merge pull request #21 from streamingfast/merge
Merge v2.1.0-beta4 into Polygon
2 parents 96ec0a7 + da476c1 commit 7f5c089

File tree

1,202 files changed

+137936
-35122
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,202 files changed

+137936
-35122
lines changed

.github/CODEOWNERS

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Lines starting with '#' are comments.
2+
# Each line is a file pattern followed by one or more owners.
3+
4+
accounts/usbwallet/ @gballet
5+
accounts/scwallet/ @gballet
6+
accounts/abi/ @gballet @MariusVanDerWijden
7+
beacon/engine/ @MariusVanDerWijden @lightclient @fjl
8+
beacon/light/ @zsfelfoldi
9+
beacon/merkle/ @zsfelfoldi
10+
beacon/types/ @zsfelfoldi @fjl
11+
beacon/params/ @zsfelfoldi @fjl
12+
cmd/evm/ @MariusVanDerWijden @lightclient
13+
core/state/ @rjl493456442
14+
crypto/ @gballet @jwasinger @fjl
15+
core/ @rjl493456442
16+
eth/ @rjl493456442
17+
eth/catalyst/ @MariusVanDerWijden @lightclient @fjl @jwasinger
18+
eth/tracers/ @s1na
19+
ethclient/ @fjl
20+
ethdb/ @rjl493456442
21+
event/ @fjl
22+
trie/ @rjl493456442
23+
triedb/ @rjl493456442
24+
core/tracing/ @s1na
25+
graphql/ @s1na
26+
internal/ethapi/ @fjl @s1na @lightclient
27+
internal/era/ @lightclient
28+
miner/ @MariusVanDerWijden @fjl @rjl493456442
29+
node/ @fjl
30+
p2p/ @fjl @zsfelfoldi
31+
rlp/ @fjl
32+
params/ @fjl @karalabe @gballet @rjl493456442 @zsfelfoldi
33+
rpc/ @fjl

.github/workflows/amoy_deb_profiles.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ jobs:
384384
uses: softprops/action-gh-release@v2
385385
with:
386386
tag_name: ${{ env.GIT_TAG }}
387-
prerelease: true
387+
make_latest: false
388388
files: |
389389
packaging/deb/bor-amoy-**.deb
390390
packaging/deb/bor-pbss-amoy-**.deb

.github/workflows/ci.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ jobs:
110110
- name: Test
111111
run: make test
112112

113-
- uses: actions/upload-artifact@v4.4.0
113+
- uses: PaloAltoNetworks/upload-secure-artifact@main
114114
with:
115115
name: unitTest-coverage
116116
path: cover.out
@@ -161,7 +161,7 @@ jobs:
161161
- name: test-integration
162162
run: make test-integration
163163

164-
- uses: actions/upload-artifact@v4.4.0
164+
- uses: PaloAltoNetworks/upload-secure-artifact@main
165165
with:
166166
name: integrationTest-coverage
167167
path: cover.out
@@ -275,13 +275,17 @@ jobs:
275275
echo "Starting RPC Tests..."
276276
timeout 5m bash bor/integration-tests/rpc_test.sh
277277
278+
- name: Resolve absolute path for logs
279+
id: pathfix
280+
run: |
281+
echo "ABS_LOG_PATH=$(realpath matic-cli/devnet/logs)" >> $GITHUB_ENV
282+
278283
- name: Upload logs
279284
if: always()
280-
uses: actions/upload-artifact@v4.4.0
285+
uses: PaloAltoNetworks/upload-secure-artifact@main
281286
with:
282287
name: logs_${{ github.run_id }}
283-
path: |
284-
matic-cli/devnet/logs
288+
path: ${{ env.ABS_LOG_PATH }}
285289

286290
- name: Package code and chain data
287291
if: always()
@@ -292,11 +296,11 @@ jobs:
292296
mkdir -p ${{ github.run_id }}/matic-cli
293297
sudo mv bor ${{ github.run_id }}
294298
sudo mv matic-cli/devnet ${{ github.run_id }}/matic-cli
295-
sudo tar czf code.tar.gz ${{ github.run_id }}
299+
sudo tar --warning=no-file-changed --exclude='.git' -czf code.tar.gz ${{ github.run_id }}
296300
297301
- name: Upload code and chain data
298302
if: always()
299-
uses: actions/upload-artifact@v4.4.0
303+
uses: PaloAltoNetworks/upload-secure-artifact@main
300304
with:
301305
name: code_${{ github.run_id }}
302306
path: code.tar.gz

.github/workflows/go.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: i386 linux tests
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
workflow_dispatch:
9+
10+
jobs:
11+
lint:
12+
name: Lint
13+
runs-on: self-hosted
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
# Cache build tools to avoid downloading them each time
18+
- uses: actions/cache@v4
19+
with:
20+
path: build/cache
21+
key: ${{ runner.os }}-build-tools-cache-${{ hashFiles('build/checksums.txt') }}
22+
23+
- name: Set up Go
24+
uses: actions/setup-go@v5
25+
with:
26+
go-version: 1.23.0
27+
cache: false
28+
29+
- name: Run linters
30+
run: |
31+
go run build/ci.go lint
32+
go run build/ci.go check_generate
33+
go run build/ci.go check_baddeps
34+
35+
build:
36+
runs-on: self-hosted
37+
steps:
38+
- uses: actions/checkout@v4
39+
- name: Set up Go
40+
uses: actions/setup-go@v5
41+
with:
42+
go-version: 1.24.0
43+
cache: false
44+
- name: Run tests
45+
run: go test -short ./...
46+
env:
47+
GOOS: linux
48+
GOARCH: 386

.github/workflows/mainnet_deb_profiles.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,7 @@ jobs:
394394
uses: softprops/action-gh-release@v2
395395
with:
396396
tag_name: ${{ env.GIT_TAG }}
397-
prerelease: true
397+
make_latest: false
398398
files: |
399399
packaging/deb/bor-mainnet-**.deb
400400
packaging/deb/bor-pbss-mainnet-**.deb

.github/workflows/packager_deb.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ jobs:
122122
uses: softprops/action-gh-release@v2
123123
with:
124124
tag_name: ${{ env.GIT_TAG }}
125-
prerelease: true
125+
make_latest: false
126126
files: |
127127
packaging/deb/bor**.deb
128128
packaging/deb/bor**.deb.checksum

.github/workflows/sf-release.yml

Lines changed: 174 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,174 @@
1+
name: Build, push and release (if tag)
2+
3+
on:
4+
push:
5+
tags:
6+
- "*-v*"
7+
branches:
8+
- "firehose-fh3.0"
9+
- "release/*"
10+
11+
env:
12+
REGISTRY: ghcr.io
13+
IMAGE_NAME: ${{ github.repository }}
14+
15+
jobs:
16+
build:
17+
strategy:
18+
matrix:
19+
include:
20+
- platform: linux/amd64
21+
platform_suffix: amd64
22+
runner: ubuntu-22.04
23+
24+
- platform: linux/arm64
25+
platform_suffix: arm64
26+
runner: ubuntu-22.04-arm
27+
28+
runs-on: [ "${{ matrix.runner }}" ]
29+
30+
steps:
31+
- name: Checkout repository
32+
uses: actions/checkout@v4
33+
34+
- name: Set up Docker Buildx
35+
uses: docker/setup-buildx-action@v3
36+
37+
- name: Log in to the Container registry
38+
uses: docker/login-action@v3
39+
with:
40+
registry: ${{ env.REGISTRY }}
41+
username: ${{ github.actor }}
42+
password: ${{ secrets.GITHUB_TOKEN }}
43+
44+
- name: Extract version
45+
id: extract-version
46+
run: |
47+
version="edge"
48+
if [[ "${GITHUB_REF}" == refs/tags/* ]]; then
49+
version=${GITHUB_REF#refs/tags/}
50+
fi
51+
52+
echo "VERSION=${version}" >> "$GITHUB_OUTPUT"
53+
54+
- name: Generate docker tags/labels from github build context
55+
id: meta
56+
uses: docker/metadata-action@v5
57+
with:
58+
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
59+
# The second sha tag is defined to uniquely identify the image and the platform,
60+
# we append extract version, either edge or <tag>, this is necessary to avoid a
61+
# race condition when pushing a tag and its related branches. In this case, three
62+
# build are launched, but only one, the tag, will get it's version set to the tag.
63+
#
64+
# What happened is that non-tag Docker built image like `3b14725-amd64` was
65+
# overwriting the tag Docker image also labeled `3b14725-amd64`. The `push` action
66+
# was then merging an image that didn't have the version labels correctly set.
67+
#
68+
# Our image more looks like `3b14725-edge-amd64` or `3b14725-geth-v1.15.10-fh3.0-amd64`
69+
# which mean the `push` can now pick the correct image depending on the type of build.
70+
tags: |
71+
type=ref,event=tag,prefix=
72+
type=sha,prefix=
73+
type=sha,prefix=,suffix=-${{ steps.extract-version.outputs.VERSION }}-${{ matrix.platform_suffix }}
74+
type=edge,branch=firehose-fh3.0,priority=1
75+
type=edge,branch=release/*,priority=1
76+
flavor: |
77+
latest=${{ startsWith(github.ref, 'refs/tags/') && !contains(github.ref, 'beta') && !contains(github.ref, 'rc') }}
78+
prefix=geth-,onlatest=true
79+
80+
- name: Build and push Docker image (${{ matrix.platform }})
81+
uses: docker/build-push-action@v6
82+
with:
83+
context: .
84+
file: ./Dockerfile.sf
85+
platforms: ${{ matrix.platform }}
86+
push: true
87+
tags: ${{ steps.meta.outputs.tags }}
88+
labels: ${{ steps.meta.outputs.labels }}
89+
provenance: false
90+
# FIXME: Switch to Firehose Ethereum!
91+
build-args: |
92+
FIREHOSE_CORE=18bb86f
93+
94+
push:
95+
needs: build
96+
runs-on: ubuntu-22.04
97+
98+
permissions:
99+
contents: read
100+
packages: write
101+
102+
steps:
103+
- name: Docker login
104+
uses: docker/login-action@v3
105+
with:
106+
registry: ${{ env.REGISTRY }}
107+
username: ${{ github.actor }}
108+
password: ${{ secrets.GITHUB_TOKEN }}
109+
110+
- name: Generate docker tags/labels from github build context
111+
id: meta
112+
uses: docker/metadata-action@v5
113+
with:
114+
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
115+
tags: |
116+
type=ref,event=tag,prefix=
117+
type=sha,prefix=
118+
type=edge,branch=firehose-fh3.0,priority=1
119+
type=edge,branch=release/*,priority=1
120+
flavor: |
121+
latest=${{ startsWith(github.ref, 'refs/tags/') && !contains(github.ref, 'beta') && !contains(github.ref, 'rc') }}
122+
prefix=geth-,onlatest=true
123+
sep-tags: ","
124+
125+
- name: Extract image
126+
id: image
127+
run: |
128+
version="edge"
129+
if [[ "${GITHUB_REF}" == refs/tags/* ]]; then
130+
version=${GITHUB_REF#refs/tags/}
131+
fi
132+
133+
echo "ID=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${GITHUB_SHA::7}-${version}" >> "$GITHUB_OUTPUT"
134+
135+
- name: Create and push manifest images
136+
uses: Noelware/docker-manifest-action@0.4.3
137+
with:
138+
inputs: "${{ steps.meta.outputs.tags }}"
139+
images: "${{ steps.image.outputs.ID }}-amd64, ${{ steps.image.outputs.ID }}-arm64"
140+
push: true
141+
142+
release:
143+
if: startsWith(github.ref, 'refs/tags/')
144+
needs: build
145+
runs-on: ubuntu-22.04
146+
147+
permissions:
148+
contents: write
149+
150+
steps:
151+
- name: Extract image
152+
id: image
153+
run: |
154+
version="edge"
155+
if [[ "${GITHUB_REF}" == refs/tags/* ]]; then
156+
version=${GITHUB_REF#refs/tags/}
157+
fi
158+
159+
echo "ID=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${GITHUB_SHA::7}-${version}" >> "$GITHUB_OUTPUT"
160+
161+
- name: Extract assets
162+
if: startsWith(github.ref, 'refs/tags/')
163+
run: |
164+
# The --platform are not really needed here, but it removes the warning
165+
docker cp $(docker create --platform=linux/amd64 ${{ steps.image.outputs.ID }}-amd64):/usr/local/bin/geth ./geth_linux
166+
docker cp $(docker create --platform=linux/arm64 ${{ steps.image.outputs.ID }}-arm64):/usr/local/bin/geth ./geth_linux_arm64
167+
168+
- name: Release
169+
uses: softprops/action-gh-release@v2
170+
with:
171+
prerelease: ${{ contains(github.ref, 'beta') || contains(github.ref, 'rc') }}
172+
files: |
173+
./geth_linux
174+
./geth_linux_arm64

.gitignore

Lines changed: 14 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,11 @@
44
# or operating system, you probably want to add a global ignore instead:
55
# git config --global core.excludesfile ~/.gitignore_global
66

7-
/tmp
87
*/**/*un~
98
*/**/*.test
109
*un~
1110
.DS_Store
1211
*/**/.DS_Store
13-
.ethtest
14-
*/**/*tx_database*
15-
*/**/*dapps*
16-
build/_vendor/pkg
1712

1813
cover.out
1914

@@ -44,27 +39,22 @@ profile.cov
4439

4540
# IdeaIDE
4641
.idea
42+
*.iml
4743

4844
# VS Code
4945
.vscode
5046

51-
# dashboard
52-
/dashboard/assets/flow-typed
53-
/dashboard/assets/node_modules
54-
/dashboard/assets/stats.json
55-
/dashboard/assets/bundle.js
56-
/dashboard/assets/bundle.js.map
57-
/dashboard/assets/package-lock.json
58-
59-
**/yarn-error.log
60-
./test
61-
./bor-debug-*
62-
63-
dist
64-
65-
.dccache
66-
67-
*.csv
68-
logs/
69-
7047
tests/spec-tests/
48+
49+
# binaries
50+
cmd/abidump/abidump
51+
cmd/abigen/abigen
52+
cmd/blsync/blsync
53+
cmd/clef/clef
54+
cmd/devp2p/devp2p
55+
cmd/era/era
56+
cmd/ethkey/ethkey
57+
cmd/evm/evm
58+
cmd/geth/geth
59+
cmd/rlpdump/rlpdump
60+
cmd/workload/workload

0 commit comments

Comments
 (0)