From 5b4b311a73323b183ebcc6cc053e52f38d6e1d98 Mon Sep 17 00:00:00 2001 From: Theodore Turocy Date: Wed, 23 Sep 2026 14:51:11 +0100 Subject: [PATCH 1/4] Smoke test for potential wheel packaging problems --- .github/workflows/wheel-smoke.yml | 27 +++++++++++++++++++++++++++ .github/workflows/wheels.yml | 2 +- pyproject.toml | 5 ++++- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/wheel-smoke.yml diff --git a/.github/workflows/wheel-smoke.yml b/.github/workflows/wheel-smoke.yml new file mode 100644 index 0000000000..73695305bd --- /dev/null +++ b/.github/workflows/wheel-smoke.yml @@ -0,0 +1,27 @@ + +name: pygambit wheel smoke test + +on: + push: + pull_request: + +jobs: + windows-cp314: + runs-on: windows-latest + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + + steps: + - uses: actions/checkout@v7 + - name: Set up Python + uses: actions/setup-python@v7 + with: + python-version: '3.x' + - name: Set up dependencies + run: | + python -m pip install --upgrade pip + pip install cython==3.3.0 wheel lxml numpy scipy cibuildwheel==4.2.1 + - name: Build and smoke-test cp314 Windows wheel + run: | + python -m cibuildwheel --output-dir wheelhouse/ + env: + CIBW_BUILD: "cp314-win_amd64" diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index c7232128c8..a2c65209e4 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -22,7 +22,7 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - pip install cython nose2 wheel lxml numpy scipy cibuildwheel + pip install cython==3.3.0 nose2 wheel lxml numpy scipy cibuildwheel==4.2.1 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse/ diff --git a/pyproject.toml b/pyproject.toml index 6826e78f2d..ce639e0c87 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools", "wheel", "Cython"] +requires = ["setuptools", "wheel", "Cython==3.3.0"] build-backend = "setuptools.build_meta" [project] @@ -137,6 +137,9 @@ markers = [ "catalog_update: tests of catalog/build.py", ] +[tool.cibuildwheel] +test-command = "python -c \"import pygambit\"" + [tool.setuptools] packages = ["pygambit", "pygambit.cli"] package-dir = { "pygambit" = "src/pygambit" } From 0d5bfabb962f5a9864173fdb47ccb0ae5201cd61 Mon Sep 17 00:00:00 2001 From: Theodore Turocy Date: Wed, 23 Sep 2026 16:13:18 +0100 Subject: [PATCH 2/4] Revert pins --- .github/workflows/wheel-smoke.yml | 2 +- .github/workflows/wheels.yml | 2 +- pyproject.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/wheel-smoke.yml b/.github/workflows/wheel-smoke.yml index 73695305bd..66f9e50a6e 100644 --- a/.github/workflows/wheel-smoke.yml +++ b/.github/workflows/wheel-smoke.yml @@ -19,7 +19,7 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - pip install cython==3.3.0 wheel lxml numpy scipy cibuildwheel==4.2.1 + pip install cython wheel lxml numpy scipy cibuildwheel - name: Build and smoke-test cp314 Windows wheel run: | python -m cibuildwheel --output-dir wheelhouse/ diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index a2c65209e4..c7232128c8 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -22,7 +22,7 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - pip install cython==3.3.0 nose2 wheel lxml numpy scipy cibuildwheel==4.2.1 + pip install cython nose2 wheel lxml numpy scipy cibuildwheel - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse/ diff --git a/pyproject.toml b/pyproject.toml index ce639e0c87..43cc93f336 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools", "wheel", "Cython==3.3.0"] +requires = ["setuptools", "wheel", "Cython"] build-backend = "setuptools.build_meta" [project] From 9476daeae941e1cb5a3efffaba0d3b536c363d70 Mon Sep 17 00:00:00 2001 From: Theodore Turocy Date: Wed, 23 Sep 2026 16:49:36 +0100 Subject: [PATCH 3/4] Try different pin for smoke test --- .github/workflows/wheel-smoke.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/wheel-smoke.yml b/.github/workflows/wheel-smoke.yml index 66f9e50a6e..a245a75fd6 100644 --- a/.github/workflows/wheel-smoke.yml +++ b/.github/workflows/wheel-smoke.yml @@ -19,7 +19,9 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - pip install cython wheel lxml numpy scipy cibuildwheel + # Pinned to reproduce the toolchain combo in effect when v16.7.0 was tagged (2026-07-11): + # cython 3.2.8 and cibuildwheel 4.1.0 were the latest available at that date. + pip install cython==3.2.8 wheel lxml numpy scipy cibuildwheel==4.1.0 - name: Build and smoke-test cp314 Windows wheel run: | python -m cibuildwheel --output-dir wheelhouse/ From c10a06a057e2d1b2e6f29ef682c8eba4cde83bd1 Mon Sep 17 00:00:00 2001 From: Theodore Turocy Date: Mon, 28 Sep 2026 13:27:05 +0100 Subject: [PATCH 4/4] Parallelise and test pygambit wheel builds --- .github/workflows/wheel-smoke.yml | 5 +---- .github/workflows/wheels.yml | 17 ++++++++++++----- pyproject.toml | 3 ++- 3 files changed, 15 insertions(+), 10 deletions(-) diff --git a/.github/workflows/wheel-smoke.yml b/.github/workflows/wheel-smoke.yml index a245a75fd6..622faa5c28 100644 --- a/.github/workflows/wheel-smoke.yml +++ b/.github/workflows/wheel-smoke.yml @@ -2,7 +2,6 @@ name: pygambit wheel smoke test on: - push: pull_request: jobs: @@ -19,9 +18,7 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - # Pinned to reproduce the toolchain combo in effect when v16.7.0 was tagged (2026-07-11): - # cython 3.2.8 and cibuildwheel 4.1.0 were the latest available at that date. - pip install cython==3.2.8 wheel lxml numpy scipy cibuildwheel==4.1.0 + pip install cibuildwheel - name: Build and smoke-test cp314 Windows wheel run: | python -m cibuildwheel --output-dir wheelhouse/ diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index c7232128c8..fecbdf1310 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -10,8 +10,14 @@ on: workflow_dispatch: jobs: - windows: - runs-on: windows-latest + wheels: + strategy: + fail-fast: false + matrix: + os: [windows-latest, ubuntu-latest, macos-14] + python-tag: [cp310, cp311, cp312, cp313, cp314] + + runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v7 @@ -22,14 +28,15 @@ jobs: - name: Set up dependencies run: | python -m pip install --upgrade pip - pip install cython nose2 wheel lxml numpy scipy cibuildwheel - - name: Build wheels + pip install cibuildwheel + - name: Build and smoke-test wheel run: | python -m cibuildwheel --output-dir wheelhouse/ env: - CIBW_SKIP: "pp*" + CIBW_BUILD: "${{ matrix.python-tag }}-*" - uses: actions/upload-artifact@v7 with: + name: wheels-${{ matrix.os }}-${{ matrix.python-tag }} path: ./wheelhouse/*.whl sdist: diff --git a/pyproject.toml b/pyproject.toml index 43cc93f336..a372019429 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -138,7 +138,8 @@ markers = [ ] [tool.cibuildwheel] -test-command = "python -c \"import pygambit\"" +skip = "pp* *t" +test-command = "python -c \"import pygambit; g = pygambit.Game.new_table([2, 2]); assert g\"" [tool.setuptools] packages = ["pygambit", "pygambit.cli"]