From 742eda10307937000e97cc9d05f44bf92846adcc Mon Sep 17 00:00:00 2001 From: Tim Besard Date: Tue, 1 Dec 2026 10:41:13 +0100 Subject: [PATCH] Update to JuliaGPU Buildkite changes Fork PRs are no longer built directly on the GPU agents, which also no longer decrypt secrets. Approved fork commits are pushed to ci/pr- by JuliaCI/buildkite-pr-relay and built from there. Coverage is uploaded tokenless, replacing SECRET_CODECOV_TOKEN. --- .buildkite/pipeline.yml | 19 +++++++++++-------- .github/workflows/BuildkiteApproval.yml | 14 ++++++++++++++ .github/workflows/BuildkiteRelay.yml | 20 ++++++++++++++++++++ 3 files changed, 45 insertions(+), 8 deletions(-) create mode 100644 .github/workflows/BuildkiteApproval.yml create mode 100644 .github/workflows/BuildkiteRelay.yml diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml index 8ae0b79f1..7ee178201 100644 --- a/.buildkite/pipeline.yml +++ b/.buildkite/pipeline.yml @@ -1,3 +1,7 @@ +# Pull requests from forks are built from a `ci/pr-` branch once a maintainer has approved +# their commit (see .github/workflows/BuildkiteRelay.yml); those builds count as pull +# requests below. +# # Tests of the KernelAbstractions-related parts of the GPU back-ends, and the benchmarks. Draft # pull requests skip them, unless selected by name in the last commit message: `[only cuda]`, # `[only metal, oneapi]`, `[only tests]` for all tests, or `[only benchmarks]`. `[skip amdgpu]` @@ -59,7 +63,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|cuda|julia)/ && (build.message =~ /\[only [^\]]*(tests|cuda|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) # The Enzyme extension on the GPU back ends, whose own test suites don't run # test/extensions/enzyme.jl. The back ends implement `EnzymeCore.compiler_job_from_backend`. @@ -116,7 +120,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|cuda|enzyme|julia)/ && (build.message =~ /\[only [^\]]*(tests|cuda|enzyme|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) - &amdgpu_enzyme label: "AMDGPU Enzyme Julia {{matrix.version}}" @@ -172,7 +176,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|amdgpu|enzyme|julia)/ && (build.message =~ /\[only [^\]]*(tests|amdgpu|enzyme|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) - &metal label: "Metal Julia {{matrix.version}}" @@ -219,7 +223,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|metal|julia)/ && (build.message =~ /\[only [^\]]*(tests|metal|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) - &oneapi label: "oneAPI Julia {{matrix.version}}" @@ -269,7 +273,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|oneapi|julia)/ && (build.message =~ /\[only [^\]]*(tests|oneapi|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) - &amdgpu label: "AMDGPU Julia {{matrix.version}}" @@ -321,7 +325,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|amdgpu|julia)/ && (build.message =~ /\[only [^\]]*(tests|amdgpu|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) - &opencl label: "OpenCL Julia {{matrix.version}}" @@ -372,7 +376,7 @@ steps: if: | build.message !~ /\[skip [^\]]*(tests|opencl|julia)/ && (build.message =~ /\[only [^\]]*(tests|opencl|julia)/ || - build.message !~ /\[only / && build.pull_request.id == null) + build.message !~ /\[only / && build.pull_request.id == null && build.branch !~ /^ci\/pr-/) # the label determines the commit status context .github/workflows/Benchmark.yml reacts to - label: ":racehorse: Benchmarks" @@ -404,4 +408,3 @@ steps: env: JULIA_PKG_PRECOMPILE_AUTO: false JULIA_PKG_SERVER_REGISTRY_PREFERENCE: "eager" # see freshly-registered versions without cloning the registry - SECRET_CODECOV_TOKEN: "c5pjPUwULD2L8ss0gRtjCPiagRlTQ11TdbZP6gIhTPeA/gN5w5/7JvDCg36UpKER6FXnQDeBGGkQafHiLdBaH/FWQ2B2VKErtBarIBJa2zWvKu8mYs9PJzw/qLGT2sMXI9kcao63H6/HAwbslJcY0a5Mg+SwM3M05XqSHgnrHMnbBXysKP6VzFEIX7uoyEKOnoWDj8rGJKFYLW2DBRtd6Yc23ESfFXPAqbS7sgXxwQHKzz20FMQBJUmbiDIzPlk3k2n2TvgAWQ0VNK0e4/UooMbULL3UjY4oaMOF0XpJAnWlmvGgy8gEnZKSVp3ieXy/Ubu7BWwH/BT59wDy6LuDxA==;U2FsdGVkX18Wil69f7qJYu6yU5iNx+Zq8akUcOp+McU1CR4Jw4QBsrUKIF4W4uK+/752FQo40BwFsfnIC8CJ/Q==" diff --git a/.github/workflows/BuildkiteApproval.yml b/.github/workflows/BuildkiteApproval.yml new file mode 100644 index 000000000..3969dbf73 --- /dev/null +++ b/.github/workflows/BuildkiteApproval.yml @@ -0,0 +1,14 @@ +# Held by GitHub on pull requests from outside contributors until a maintainer approves the +# run; BuildkiteRelay.yml then has the approved commit built on Buildkite. Must stay +# trivial: it runs the pull request's copy of this file. See +# https://github.com/JuliaCI/buildkite-pr-relay. +name: Buildkite approval +on: + pull_request: + types: [opened, synchronize, reopened] +permissions: {} +jobs: + approval: + runs-on: ubuntu-latest + steps: + - run: "true" diff --git a/.github/workflows/BuildkiteRelay.yml b/.github/workflows/BuildkiteRelay.yml new file mode 100644 index 000000000..c085ea9f4 --- /dev/null +++ b/.github/workflows/BuildkiteRelay.yml @@ -0,0 +1,20 @@ +# Pushes the commit of an approved fork pull request to the branch ci/pr-, which +# Buildkite builds, and deletes the branches of closed pull requests. +# See https://github.com/JuliaCI/buildkite-pr-relay. +name: Buildkite relay +on: + workflow_run: + workflows: ["Buildkite approval"] + types: [completed] + schedule: + - cron: "37 * * * *" + workflow_dispatch: +permissions: + contents: write # push and delete ci/pr- + pull-requests: read + statuses: write +jobs: + relay: + uses: JuliaCI/buildkite-pr-relay/.github/workflows/relay.yml@v2 + with: + pipeline: kernelabstractions-dot-jl