Skip to content

Merge pull request #4247 from onflow/bastian/vm-improve-errors #12010

Merge pull request #4247 from onflow/bastian/vm-improve-errors

Merge pull request #4247 from onflow/bastian/vm-improve-errors #12010

Workflow file for this run

name: CI
on:
push:
branches:
- master
- 'feature/**'
- 'v**'
pull_request:
branches:
- master
- 'feature/**'
- 'v**'
env:
GO_VERSION: '1.23'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }}
cancel-in-progress: true
jobs:
commands-and-tools:
name: Commands and tools
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
cache: true
- name: Build
run: make -j build
- name: Test
run: make -j test-tools
linter:
name: Build linter
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
cache: true
- name: Build linter
run: make -j build-linter
- name: Test linter
run: make -j test-linter
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
cache: true
- name: Test
run: make ci
- name: Upload coverage report
uses: codecov/codecov-action@v2
with:
file: ./coverage.txt
flags: unittests
test-with-tracing:
name: Test with tracing
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
cache: true
- name: Test
run: make ci-with-tracing
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
with:
# fetch all tags.
# required to update the embedded version during code generation
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
cache: true
- name: Lint
run: make lint
- name: Check tidy
run: make check-tidy
- name: Check license headers
run: make check-headers
- name: Validate error documentation links
run: make validate-error-doc-links
lint-json:
name: Lint JSON
runs-on: ubuntu-latest
steps:
- name: Clone
uses: actions/checkout@v3
- name: json-syntax-check
uses: limitusus/json-syntax-check@v1
with:
pattern: "\\.json$"
semgrep:
name: Semgrep
runs-on: ubuntu-latest
container:
image: returntocorp/semgrep
# Skip any PR created by dependabot to avoid permission issues:
if: (github.actor != 'dependabot[bot]')
steps:
- name: Clone
uses: actions/checkout@v3
- name: semgrep ci
run: semgrep ci --config semgrep.yaml