From 43f5dedacac785fc1e1cc0ed1052381105381175 Mon Sep 17 00:00:00 2001 From: Paul Annesley Date: Fri, 3 Jul 2026 17:21:08 +0930 Subject: [PATCH 1/2] Move CI from GitHub Actions to Buildkite Add a Buildkite CI pipeline running the same matrix as the GitHub Actions workflow: pytest and pylint on Python 3.9-3.13, plus pytest>=9 on 3.13. The pipeline runs in the Open Source cluster with no secrets. Test results are dogfooded to the test-collector-python Test Engine suite using an ephemeral OIDC token instead of the long-lived BUILDKITE_ANALYTICS_TOKEN secret used by GitHub Actions. The GitHub Actions workflow stays in place until the Buildkite pipeline has proven itself; a follow-up will remove it. Amp-Thread-ID: https://ampcode.com/threads/T-019f26cf-e438-70a4-a167-1d1c45d42519 Co-authored-by: Amp --- .buildkite/pipeline.yml | 31 +++++++++++++++++++++++++++++++ .buildkite/steps/lint | 21 +++++++++++++++++++++ .buildkite/steps/test | 30 ++++++++++++++++++++++++++++++ 3 files changed, 82 insertions(+) create mode 100644 .buildkite/pipeline.yml create mode 100755 .buildkite/steps/lint create mode 100755 .buildkite/steps/test diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml new file mode 100644 index 0000000..ee1171a --- /dev/null +++ b/.buildkite/pipeline.yml @@ -0,0 +1,31 @@ +agents: + queue: hosted + +steps: + - label: ":pytest: pytest {{matrix}}" + command: ".buildkite/steps/test" + env: + PYTHON_VERSION: "{{matrix}}" + matrix: + - "3.9" + - "3.10" + - "3.11" + - "3.12" + - "3.13" + + - label: ":pytest: pytest 3.13 / pytest>=9" + command: ".buildkite/steps/test" + env: + PYTHON_VERSION: "3.13" + UV_RUN_FLAGS: "--with pytest>=9" + + - label: ":python: pylint {{matrix}}" + command: ".buildkite/steps/lint" + env: + PYTHON_VERSION: "{{matrix}}" + matrix: + - "3.9" + - "3.10" + - "3.11" + - "3.12" + - "3.13" diff --git a/.buildkite/steps/lint b/.buildkite/steps/lint new file mode 100755 index 0000000..0ee2422 --- /dev/null +++ b/.buildkite/steps/lint @@ -0,0 +1,21 @@ +#!/usr/bin/env bash + +set -o errexit +set -o pipefail +set -o nounset + +__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +__root="$(cd "$(dirname "${__dir}")"/../ && pwd)" + +cd "$__root" + +# Install uv +curl -LsSf https://astral.sh/uv/install.sh | sh +source "$HOME/.local/bin/env" + +# Install dependencies +uv python install "$PYTHON_VERSION" +uv sync --all-extras + +# Run pylint +uv run pylint src/ diff --git a/.buildkite/steps/test b/.buildkite/steps/test new file mode 100755 index 0000000..15de427 --- /dev/null +++ b/.buildkite/steps/test @@ -0,0 +1,30 @@ +#!/usr/bin/env bash + +set -o errexit +set -o pipefail +set -o nounset + +__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +__root="$(cd "$(dirname "${__dir}")"/../ && pwd)" + +cd "$__root" + +# Dogfood the collector: upload this repo's own test results to Test Engine. +# Uses an ephemeral OIDC token instead of a long-lived suite token, so this +# pipeline carries no secrets. +# https://buildkite.com/docs/pipelines/configure/tests/test-collection/oidc +SUITE_URL="https://buildkite.com/organizations/buildkite/analytics/suites/test-collector-python" +BUILDKITE_ANALYTICS_TOKEN="$(buildkite-agent oidc request-token --audience "$SUITE_URL" --lifetime 900)" +export BUILDKITE_ANALYTICS_TOKEN + +# Install uv +curl -LsSf https://astral.sh/uv/install.sh | sh +source "$HOME/.local/bin/env" + +# Install dependencies +uv python install "$PYTHON_VERSION" +uv sync --all-extras + +# Run tests (UV_RUN_FLAGS is intentionally word-split, e.g. "--with pytest>=9") +# shellcheck disable=SC2086 +uv run ${UV_RUN_FLAGS:-} pytest From d2cf3fa124a6dc81bfa818ce96ea103b0a5d1fd1 Mon Sep 17 00:00:00 2001 From: Paul Annesley Date: Fri, 3 Jul 2026 19:54:31 +0930 Subject: [PATCH 2/2] Remove GitHub Actions CI workflow CI now runs on Buildkite with the same coverage: pytest and pylint on Python 3.9-3.13, plus pytest>=9 on 3.13. Also drop the github-actions dependabot ecosystem since no workflows remain. Amp-Thread-ID: https://ampcode.com/threads/T-019f26cf-e438-70a4-a167-1d1c45d42519 Co-authored-by: Amp --- .github/dependabot.yml | 4 --- .github/workflows/python.yaml | 55 ----------------------------------- 2 files changed, 59 deletions(-) delete mode 100644 .github/workflows/python.yaml diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 7817c7d..0d23fbd 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -4,7 +4,3 @@ updates: directory: "/" schedule: interval: "daily" -- package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: "weekly" diff --git a/.github/workflows/python.yaml b/.github/workflows/python.yaml deleted file mode 100644 index 02cfbf8..0000000 --- a/.github/workflows/python.yaml +++ /dev/null @@ -1,55 +0,0 @@ -name: python - -on: - pull_request: - branches: - - main - push: - branches: - - main - -jobs: - pytest: - runs-on: ubuntu-latest - strategy: - matrix: - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] - uv-run-flags: [""] - include: - - python-version: "3.13" - uv-run-flags: "--with 'pytest>=9'" - - env: - BUILDKITE_ANALYTICS_TOKEN: ${{ secrets.BUILDKITE_ANALYTICS_TOKEN }} - - steps: - - uses: actions/checkout@v6 - - name: Install uv - uses: astral-sh/setup-uv@v7 - with: - version: "latest" - - name: Set up Python ${{ matrix.python-version }} - run: uv python install ${{ matrix.python-version }} - - name: Install dependencies - run: uv sync --all-extras - - name: Run tests - run: uv run ${{ matrix.uv-run-flags }} pytest - - pylint: - runs-on: ubuntu-latest - strategy: - matrix: - python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] - - steps: - - uses: actions/checkout@v6 - - name: Install uv - uses: astral-sh/setup-uv@v7 - with: - version: "latest" - - name: Set up Python ${{ matrix.python-version }} - run: uv python install ${{ matrix.python-version }} - - name: Install dependencies - run: uv sync --all-extras - - name: Run pylint - run: uv run pylint src/