Skip to content

Bound CHASM scheduler request IDs #26166

Bound CHASM scheduler request IDs

Bound CHASM scheduler request IDs #26166

Workflow file for this run

name: linters
on:
pull_request:
permissions:
contents: read
jobs:
lint-actions:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- name: lint actions
run: |
echo "::add-matcher::.github/actionlint-matcher.json"
bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
make lint-actions
shell: bash
lint-protos:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
submodules: true
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- uses: jdx/mise-action@dba19683ed58901619b14f395a24841710cb4925 # v4.1.0
with:
working_directory: .github
install_args: protoc
- name: lint protobuf definitions
run: |
make lint-protos
lint-api:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
submodules: true
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- uses: jdx/mise-action@dba19683ed58901619b14f395a24841710cb4925 # v4.1.0
with:
working_directory: .github
install_args: protoc
- name: lint protobuf API definitions
run: |
make lint-api
lint-workflows:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- uses: jdx/mise-action@dba19683ed58901619b14f395a24841710cb4925 # v4.1.0
with:
working_directory: .github
install_args: protoc
- name: lint system workflows with workflowcheck
run: make workflowcheck
nilaway:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- name: lint nil-safety
run: make lint-nilaway
fmt:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- name: apply formatters
run: |
make fmt
- name: check-is-dirty
run: |
if [[ -n $(git status --porcelain) ]]; then
echo "Detected uncommitted changes."
git status
git diff
exit 1
fi
parallelize-tests:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- name: check test parallelization
run: make parallelize-tests
- name: check-is-dirty
run: |
if [[ -n $(git status --porcelain) ]]; then
echo "Detected uncommitted changes after running parallelize-tests."
echo "Run 'make parallelize-tests' locally and commit the changes."
git status
git diff
exit 1
fi
golangci:
runs-on: ubuntu-24.04-arm
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: "go.mod"
check-latest: true
cache: true
- name: lint code
run: |
make GOLANGCI_LINT_FIX=false GOLANGCI_LINT_BASE_REV=HEAD~ lint-code
- name: check-is-dirty
run: |
if [[ -n $(git status --porcelain) ]]; then
echo "Detected uncommitted changes."
git status
git diff
exit 1
fi
linters-succeed:
name: All Linters Succeed
needs:
- fmt
- lint-api
- lint-protos
- lint-actions
- golangci
- parallelize-tests
- nilaway
runs-on: ubuntu-24.04-arm
if: always()
env:
RESULTS: ${{ toJSON(needs.*.result) }}
steps:
- name: Check results
run: |
if [[ -n $(echo "$RESULTS" | jq '.[] | select (. != "success")') ]]; then
exit 1
fi