Skip to content

Commit

Permalink
Merge branch 'mempool-feed-stage' into v0.3.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
zeroecco authored Dec 13, 2022
2 parents d9e5e20 + 62139de commit 26a5517
Show file tree
Hide file tree
Showing 16 changed files with 30,479 additions and 138 deletions.
76 changes: 42 additions & 34 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,43 +1,51 @@
name: Release

on:
push:
branches-ignore:
- '**'
tags:
- 'v*.*.*'
# to be used by fork patch-releases ^^
- 'v*.*.*-*'
release:
types: [created]

jobs:
goreleaser:
arm64:
name: Release Go Binary arm64
runs-on: [self-hosted, arm64]
steps:
- uses: actions/checkout@v2
- name: Build bor
run: |
cd cmd/geth && /opt/go/1.18.1/bin/go build
mv geth bor
tar -czvf bor-$(basename ${GITHUB_REF})-linux-arm64.tar.gz bor
echo $(md5sum bor | awk '{print $1}') > bor-$(basename ${GITHUB_REF})-linux-arm64.tar.gz.md5
- name: Upload bor to release page
run: |
github-assets-uploader -logtostderr -f cmd/geth/bor-$(basename ${GITHUB_REF})-linux-arm64.tar.gz -mediatype application/gzip -repo ${GITHUB_REPOSITORY} -token ${{ secrets.GITHUB_TOKEN }} -tag=$(basename ${GITHUB_REF}) -releasename="" -retry 3
github-assets-uploader -logtostderr -f cmd/geth/bor-$(basename ${GITHUB_REF})-linux-arm64.tar.gz.md5 -mediatype text/plain -repo ${GITHUB_REPOSITORY} -token ${{ secrets.GITHUB_TOKEN }} -tag=$(basename ${GITHUB_REF}) -releasename="" -retry 3
- name: Build bootnode
run: |
cd cmd/bootnode && /opt/go/1.18.1/bin/go build
tar -czvf bootnode-$(basename ${GITHUB_REF})-linux-arm64.tar.gz bootnode
echo $(md5sum bootnode | awk '{print $1}') > bootnode-$(basename ${GITHUB_REF})-linux-arm64.tar.gz.md5
- name: Upload bootnode to release page
run: |
github-assets-uploader -logtostderr -f cmd/bootnode/bootnode-$(basename ${GITHUB_REF})-linux-arm64.tar.gz -mediatype application/gzip -repo ${GITHUB_REPOSITORY} -token ${{ secrets.GITHUB_TOKEN }} -tag=$(basename ${GITHUB_REF}) -releasename="" -retry 3
github-assets-uploader -logtostderr -f cmd/bootnode/bootnode-$(basename ${GITHUB_REF})-linux-arm64.tar.gz.md5 -mediatype text/plain -repo ${GITHUB_REPOSITORY} -token ${{ secrets.GITHUB_TOKEN }} -tag=$(basename ${GITHUB_REF}) -releasename="" -retry 3
amd64:
name: Release Go Binary amd64
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/checkout@v2
- uses: wangyoucao577/[email protected]
with:
fetch-depth: 0

- name: Set up Go
uses: actions/setup-go@master
github_token: ${{ secrets.GITHUB_TOKEN }}
goos: linux
goarch: amd64
project_path: ./cmd/geth
binary_name: bor
- uses: wangyoucao577/[email protected]
with:
go-version: 1.17.x

- name: Prepare
id: prepare
run: |
TAG=${GITHUB_REF#refs/tags/}
echo ::set-output name=tag_name::${TAG}
- name: Set up QEMU
uses: docker/setup-qemu-action@v1

- name: Run GoReleaser
run: |
make release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VERSION: ${{ steps.prepare.outputs.tag_name }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
DOCKER_USERNAME: ${{ secrets.DOCKERHUB }}
DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_KEY }}
github_token: ${{ secrets.GITHUB_TOKEN }}
goos: linux
goarch: amd64
project_path: ./cmd/bootnode
binary_name: bootnode
10 changes: 10 additions & 0 deletions accounts/abi/bind/backends/dropped_tx_subscription.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package backends

import (
"github.com/ethereum/go-ethereum/core"
"github.com/ethereum/go-ethereum/event"
)

func (fb *filterBackend) SubscribeDropTxsEvent(ch chan<- core.DropTxsEvent) event.Subscription {
return nullSubscription()
}
25 changes: 25 additions & 0 deletions consensus/bor/bor_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package bor

import (
"encoding/json"
"math/big"
"testing"

Expand Down Expand Up @@ -140,3 +141,27 @@ func TestEncodeSigHeaderJaipur(t *testing.T) {
hash = SealHash(h, &params.BorConfig{JaipurBlock: 10})
assert.Equal(t, hash, hashWithoutBaseFee)
}

func TestReadHardcodedSpan(t *testing.T) {
// t.Skip()

var spanArray []*ResponseWithHeight

if err := json.Unmarshal([]byte(SPANS), &spanArray); err != nil {
t.Fatal(err)

}

for i, val := range spanArray {

var tempHeimdallSpan HeimdallSpan

if err := json.Unmarshal(val.Result, &tempHeimdallSpan); err != nil {
t.Fatal(err)
}

t.Log(i, tempHeimdallSpan.ID)

}

}
Loading

0 comments on commit 26a5517

Please sign in to comment.