Skip to content

fix(core/txpool): demote error log to warn (#1034) #48

fix(core/txpool): demote error log to warn (#1034)

fix(core/txpool): demote error log to warn (#1034) #48

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
merge_group:
types: [checks_requested]
workflow_dispatch:
inputs:
avalanchegoRepo:
description: "avalanchego github repository"
required: true
default: "ava-labs/avalanchego"
avalanchegoBranch:
description: "avalanchego branch"
required: true
default: "master"
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: check out ${{ github.event.inputs.avalanchegoRepo }} ${{ github.event.inputs.avalanchegoBranch }}
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/checkout@v4
with:
repository: ${{ github.event.inputs.avalanchegoRepo }}
ref: ${{ github.event.inputs.avalanchegoBranch }}
path: avalanchego
- uses: actions/setup-go@v5
with:
go-version-file: "go.mod"
- name: change avalanchego dep
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
go mod edit -replace github.com/ava-labs/avalanchego=./avalanchego
go mod tidy
go clean -modcache
- run: ./scripts/lint_allowed_eth_imports.sh
shell: bash
- name: Run linters
shell: bash
run: ./scripts/lint.sh
- name: Run shellcheck
shell: bash
run: scripts/shellcheck.sh
- name: Run actionlint
shell: bash
run: scripts/actionlint.sh
- name: Ensure consistent avalanchego version
shell: bash
run: |
./scripts/update_avalanchego_version.sh
git diff --exit-code
test:
name: Golang Unit Tests (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macos-latest, ubuntu-22.04, ubuntu-latest]
steps:
- uses: actions/checkout@v4
- name: check out ${{ github.event.inputs.avalanchegoRepo }} ${{ github.event.inputs.avalanchegoBranch }}
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/checkout@v4
with:
repository: ${{ github.event.inputs.avalanchegoRepo }}
ref: ${{ github.event.inputs.avalanchegoBranch }}
path: avalanchego
- uses: actions/setup-go@v5
with:
go-version-file: "go.mod"
- name: change avalanchego dep
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
go mod edit -replace github.com/ava-labs/avalanchego=./avalanchego
go mod tidy
- run: go mod download
shell: bash
- name: go mod tidy
run: |
go mod tidy
git diff --exit-code
- name: Mocks are up to date
shell: bash
run: |
grep -lr -E '^// Code generated by MockGen\. DO NOT EDIT\.$' . | xargs -r rm
go generate -run "go.uber.org/mock/mockgen" ./...
git add --intent-to-add --all
git diff --exit-code
- name: fjl/gencodec generated files are up to date
run: |
grep -lr -E '^// Code generated by github\.com\/fjl\/gencodec\. DO NOT EDIT\.$' . | xargs -r rm
go generate -run "github.com/fjl/gencodec" ./...
git add --intent-to-add --all
git diff --exit-code
- run: ./scripts/build.sh evm
shell: bash
- run: ./scripts/build_test.sh
shell: bash
env:
TIMEOUT: ${{ env.TIMEOUT }}
- run: ./scripts/coverage.sh
shell: bash
avalanchego_e2e:
name: AvalancheGo E2E Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: check out ${{ github.event.inputs.avalanchegoRepo }} ${{ github.event.inputs.avalanchegoBranch }}
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/checkout@v4
with:
repository: ${{ github.event.inputs.avalanchegoRepo }}
ref: ${{ github.event.inputs.avalanchegoBranch }}
path: avalanchego
token: ${{ secrets.AVALANCHE_PAT }}
- uses: actions/setup-go@v5
with:
go-version-file: "go.mod"
- name: Build AvalancheGo and update Coreth dependency
run: ./scripts/build_avalanchego_with_coreth.sh
- name: Run e2e tests
uses: ava-labs/avalanchego/.github/actions/run-monitored-tmpnet-cmd@ce450499b7d7c3f7b8927185b6a7b778856a702e
with:
run: ./scripts/tests.e2e.sh
run_env: AVALANCHEGO_CLONE_PATH=avalanchego
prometheus_username: ${{ secrets.PROMETHEUS_ID || '' }}
prometheus_password: ${{ secrets.PROMETHEUS_PASSWORD || '' }}
loki_username: ${{ secrets.LOKI_ID || '' }}
loki_password: ${{ secrets.LOKI_PASSWORD || '' }}
e2e_warp:
name: e2e warp tests
runs-on: ubuntu-latest
steps:
- name: Git checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: "go.mod"
- name: check out ${{ github.event.inputs.avalanchegoRepo }} ${{ github.event.inputs.avalanchegoBranch }}
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/checkout@v4
with:
repository: ${{ github.event.inputs.avalanchegoRepo }}
ref: ${{ github.event.inputs.avalanchegoBranch }}
path: avalanchego
- name: Move AvalancheGo
if: ${{ github.event_name == 'workflow_dispatch' }}
run: mv avalanchego /tmp/e2e/warp/avalanchego
- name: Build AvalancheGo and update Coreth dependency
run: ./scripts/build_avalanchego_with_coreth.sh
env:
AVALANCHEGO_CLONE_PATH: /tmp/e2e/warp/avalanchego
- name: Run Warp E2E Tests
uses: ava-labs/avalanchego/.github/actions/run-monitored-tmpnet-cmd@ce450499b7d7c3f7b8927185b6a7b778856a702e
with:
run: ./scripts/run_ginkgo_warp.sh
run_env: AVALANCHEGO_BUILD_PATH=/tmp/e2e/warp/avalanchego/build
artifact_prefix: warp
prometheus_username: ${{ secrets.PROMETHEUS_ID || '' }}
prometheus_password: ${{ secrets.PROMETHEUS_PASSWORD || '' }}
loki_username: ${{ secrets.LOKI_ID || '' }}
loki_password: ${{ secrets.LOKI_PASSWORD || '' }}