From 251d8f1a9ea0b9f984ed4260385b86a6ffe23132 Mon Sep 17 00:00:00 2001 From: Evert Lammerts Date: Mon, 14 Jul 2025 14:10:57 +0200 Subject: [PATCH 1/2] Fix on-pr workflow (#4) Fix PR workflow to use the correct git refs for checkout --- .github/workflows/coverage.yml | 7 ++++--- .github/workflows/on_pr.yml | 6 +++--- .github/workflows/pypi_packaging.yml | 7 +++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 2c05d032..fdd2a838 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -5,11 +5,11 @@ on: git_ref: type: string description: Git ref of the DuckDB python package - default: refs/heads/main - required: true + required: false duckdb_git_ref: type: string description: Git ref of DuckDB + required: false testsuite: type: choice description: Testsuite to run ('all' or 'fast') @@ -23,9 +23,10 @@ on: git_ref: type: string description: Git ref of the DuckDB python package - required: true + required: false duckdb_git_ref: type: string + required: false testsuite: type: string description: Testsuite to run ('all' or 'fast') diff --git a/.github/workflows/on_pr.yml b/.github/workflows/on_pr.yml index 5b727166..81fd3247 100644 --- a/.github/workflows/on_pr.yml +++ b/.github/workflows/on_pr.yml @@ -19,6 +19,7 @@ concurrency: cancel-in-progress: true jobs: + packaging_test: name: Build a minimal set of packages and run all tests on them # Skip packaging tests for draft PRs @@ -27,13 +28,12 @@ jobs: with: minimal: true testsuite: all - git_ref: ${{ github.ref }} - duckdb_git_ref: ${{ github.ref_name }} + duckdb_git_ref: ${{ github.base_ref }} coverage_test: name: Run coverage tests if: ${{ github.event_name != 'pull_request' || github.event.pull_request.draft == false }} uses: ./.github/workflows/coverage.yml with: - git_ref: ${{ github.ref }} + duckdb_git_ref: ${{ github.base_ref }} testsuite: all diff --git a/.github/workflows/pypi_packaging.yml b/.github/workflows/pypi_packaging.yml index a7f659f9..ef4f527a 100644 --- a/.github/workflows/pypi_packaging.yml +++ b/.github/workflows/pypi_packaging.yml @@ -19,8 +19,7 @@ on: git_ref: type: string description: Git ref of the DuckDB python package - required: true - default: refs/heads/main + required: false duckdb_git_ref: type: string description: Git ref of DuckDB @@ -44,11 +43,11 @@ on: git_ref: type: string description: Git ref of the DuckDB python package - required: true + required: false duckdb_git_ref: type: string description: Git ref of DuckDB - required: true + required: false force_version: description: Force version (vX.Y.Z-((rc|post)N)) required: false From 70b551f31410499a7e03f5242728dcb8a077885e Mon Sep 17 00:00:00 2001 From: Evert Lammerts Date: Mon, 14 Jul 2025 14:19:18 +0200 Subject: [PATCH 2/2] Nightly python builds (#5) Add workflow for external dispatch --- .github/workflows/on_external_dispatch.yml | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/on_external_dispatch.yml diff --git a/.github/workflows/on_external_dispatch.yml b/.github/workflows/on_external_dispatch.yml new file mode 100644 index 00000000..3604ce34 --- /dev/null +++ b/.github/workflows/on_external_dispatch.yml @@ -0,0 +1,28 @@ +name: Builds triggered externally by DuckDB +on: + workflow_dispatch: + inputs: + duckdb-sha: + type: string + description: The DuckDB SHA to build against + required: true + force_version: + type: string + description: Force version (vX.Y.Z-((rc|post)N)) + required: false + publish_to_pypi: + type: boolean + description: Publish packages to PyPI? + required: true + default: false + +jobs: + externally_triggered_build: + name: Build and test releases + uses: ./.github/workflows/pypi_packaging.yml + with: + minimal: false + testsuite: all + git_ref: ${{ github.ref }} + duckdb_git_ref: ${{ inputs.duckdb-sha }} + force_version: ${{ inputs.force_version }}