mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-09 13:28:01 -05:00
* `logProposedBlock`: Fix log. Before, the value of the pointer to the function were printed for `blockNumber` instead of the block number itself. * Add blob prefix before sidecars. In order to prepare for data columns sidecars. * Verification: Add log prefix. * `validate_aggregate_proof.go`: Add comments. * `blobSubscriber`: Fix error message. * `registerHandlers`: Rename, add comments and little refactor. * Remove duplicate `pb` vs. `ethpb` import. * `rpc_ping.go`: Factorize / Add comments. * `blobSidecarsByRangeRPCHandler`: Do not write error response if rate limited. * `sendRecentBeaconBlocksRequest` ==> `sendBeaconBlocksRequest`. The function itself does not know anything about the age of the beacon block. * `beaconBlocksByRangeRPCHandler`: Refactor and add logs. * `retentionSeconds` ==> `retentionDuration`. * `oneEpoch`: Add documentation. * `TestProposer_ProposeBlock_OK`: Improve error message. * `getLocalPayloadFromEngine`: Tiny refactor. * `eth1DataMajorityVote`: Improve log message. * Implement `ConvertPeerIDToNodeID`and do note generate random private key if peerDAS is enabled. * Remove useless `_`. * `parsePeersEnr`: Fix error mesages. * `ShouldOverrideFCU`: Fix error message. * `blocks.go`: Minor comments improvements. * CI: Upgrade golanci and enable spancheck. * `ConvertPeerIDToNodeID`: Add godoc comment. * Update CHANGELOG.md Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com> * Update beacon-chain/sync/initial-sync/service_test.go Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com> * Update beacon-chain/sync/rpc_beacon_blocks_by_range.go Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com> * Update beacon-chain/sync/rpc_blob_sidecars_by_range.go Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com> * Update beacon-chain/sync/rpc_ping.go Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com> * Remove trailing whitespace in godoc. --------- Co-authored-by: Sammy Rosso <15244892+saolyn@users.noreply.github.com>
92 lines
2.3 KiB
YAML
92 lines
2.3 KiB
YAML
name: Go
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ '*' ]
|
|
merge_group:
|
|
types: [checks_requested]
|
|
|
|
jobs:
|
|
formatting:
|
|
name: Formatting
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Go mod tidy checker
|
|
id: gomodtidy
|
|
uses: ./.github/actions/gomodtidy
|
|
|
|
gosec:
|
|
name: Gosec scan
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
GO111MODULE: on
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
- name: Set up Go 1.22
|
|
uses: actions/setup-go@v4
|
|
with:
|
|
go-version: '1.22.6'
|
|
- name: Run Gosec Security Scanner
|
|
run: | # https://github.com/securego/gosec/issues/469
|
|
export PATH=$PATH:$(go env GOPATH)/bin
|
|
go install github.com/securego/gosec/v2/cmd/gosec@v2.19.0
|
|
gosec -exclude-generated -exclude=G307 -exclude-dir=crypto/bls/herumi ./...
|
|
|
|
lint:
|
|
name: Lint
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Go 1.22
|
|
uses: actions/setup-go@v4
|
|
with:
|
|
go-version: '1.22.6'
|
|
id: go
|
|
|
|
- name: Golangci-lint
|
|
uses: golangci/golangci-lint-action@v5
|
|
with:
|
|
version: v1.56.1
|
|
args: --config=.golangci.yml --out-${NO_FUTURE}format colored-line-number
|
|
|
|
build:
|
|
name: Build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Set up Go 1.x
|
|
uses: actions/setup-go@v4
|
|
with:
|
|
go-version: '1.22.6'
|
|
id: go
|
|
|
|
- name: Check out code into the Go module directory
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Get dependencies
|
|
run: |
|
|
go get -v -t -d ./...
|
|
|
|
- name: Build
|
|
# Use blst tag to allow go and bazel builds for blst.
|
|
run: go build -v ./...
|
|
env:
|
|
CGO_CFLAGS: "-O2 -D__BLST_PORTABLE__"
|
|
# fuzz leverage go tag based stubs at compile time.
|
|
# Building and testing with these tags should be checked and enforced at pre-submit.
|
|
- name: Test for fuzzing
|
|
run: go test -tags=fuzz,develop ./... -test.run=^Fuzz
|
|
env:
|
|
CGO_CFLAGS: "-O2 -D__BLST_PORTABLE__"
|
|
|
|
# Tests run via Bazel for now...
|
|
# - name: Test
|
|
# run: go test -v ./...
|