diff --git a/.github/workflows/build_conda.yml b/.github/workflows/build_conda.yml index 27f076df..43b33821 100644 --- a/.github/workflows/build_conda.yml +++ b/.github/workflows/build_conda.yml @@ -39,6 +39,8 @@ jobs: - name: Disable upload run: conda config --set anaconda_upload no + # Pull requests build only the newest Python; pushes to main build + # every version listed in conda-recipe/conda_build_config.yaml - name: Build - run: conda-build conda-recipe + run: conda-build conda-recipe ${{ !(github.event_name == 'push' && github.ref == 'refs/heads/main') && '--python 3.14' || '' }} diff --git a/.github/workflows/build_wheel.yml b/.github/workflows/build_wheel.yml index d27abd6a..40d27e36 100644 --- a/.github/workflows/build_wheel.yml +++ b/.github/workflows/build_wheel.yml @@ -43,6 +43,10 @@ jobs: # statistics are printed after each wheel since the host cannot see them. - name: Build wheels env: + # Pull requests and manual runs build only the newest Python; pushes + # to main and releases build every version listed in pyproject.toml + CIBW_SKIP: >- + ${{ !(github.event_name == 'release' || (github.event_name == 'push' && github.ref == 'refs/heads/main')) && 'cp312-* cp313-*' || '' }} CIBW_ENVIRONMENT_WINDOWS: CMAKE_GENERATOR=Ninja CIBW_REPAIR_WHEEL_COMMAND_LINUX: >- auditwheel repair -w {dest_dir} {wheel} && sccache --show-stats diff --git a/.github/workflows/build_windows.yml b/.github/workflows/build_windows.yml index 1a562f39..f610f6ec 100644 --- a/.github/workflows/build_windows.yml +++ b/.github/workflows/build_windows.yml @@ -9,6 +9,13 @@ jobs: build: runs-on: windows-latest + strategy: + fail-fast: false + matrix: + # Pushes to main build and test every supported Python; other runs + # only the newest + python-version: ${{ fromJSON((github.event_name == 'push' && github.ref == 'refs/heads/main') && '["3.12", "3.13", "3.14"]' || '["3.14"]') }} + env: # sccache keeps compiled objects in the GitHub Actions cache, so later # runs only recompile the translation units a change affects @@ -19,7 +26,7 @@ jobs: - uses: actions/setup-python@v7 with: - python-version: "3.12" + python-version: ${{ matrix.python-version }} - name: Install Python dependencies run: python -m pip install ninja numpy matplotlib pytest pytest-check boost-histogram diff --git a/.github/workflows/build_with_docs.yml b/.github/workflows/build_with_docs.yml index 9e2dc872..451d580e 100644 --- a/.github/workflows/build_with_docs.yml +++ b/.github/workflows/build_with_docs.yml @@ -23,7 +23,7 @@ jobs: fail-fast: false matrix: platform: [ubuntu-latest, macos-latest] - python-version: ["3.12",] + python-version: ["3.14",] runs-on: ${{ matrix.platform }}