From cdae9e28a8262c7b3ae7717a625a177f9b70eaf2 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:07:24 +0530 Subject: [PATCH 01/15] Bump testing version to 0.28.0 --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b99ee74d1..eeac8ae92 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -244,7 +244,7 @@ jobs: env: CIBW_PLATFORM: pyodide CIBW_BUILD: "cp312*" - CIBW_PYODIDE_VERSION: "0.27.6" + CIBW_PYODIDE_VERSION: "0.28.0" - name: Run tests with 'CIBW_PLATFORM' set to 'pyodide' run: | From 58c8c04eb3c8391f4b1da8e367c6b62aedb5f866 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:07:37 +0530 Subject: [PATCH 02/15] Bump Pyodide constraints --- cibuildwheel/resources/constraints-pyodide312.txt | 2 +- cibuildwheel/resources/constraints-pyodide313.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cibuildwheel/resources/constraints-pyodide312.txt b/cibuildwheel/resources/constraints-pyodide312.txt index 990988404..17fed8061 100644 --- a/cibuildwheel/resources/constraints-pyodide312.txt +++ b/cibuildwheel/resources/constraints-pyodide312.txt @@ -94,7 +94,7 @@ typer==0.16.0 # auditwheel-emscripten # pyodide-build # pyodide-cli -typing-extensions==4.14.0 +typing-extensions==4.14.1 # via # anyio # pydantic diff --git a/cibuildwheel/resources/constraints-pyodide313.txt b/cibuildwheel/resources/constraints-pyodide313.txt index 34832e66f..ecae8c1bf 100644 --- a/cibuildwheel/resources/constraints-pyodide313.txt +++ b/cibuildwheel/resources/constraints-pyodide313.txt @@ -94,7 +94,7 @@ typer==0.16.0 # auditwheel-emscripten # pyodide-build # pyodide-cli -typing-extensions==4.14.0 +typing-extensions==4.14.1 # via # pydantic # pydantic-core From 39282c89289f18563a1c4754ea507b246c17f778 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:07:47 +0530 Subject: [PATCH 03/15] Add Pyodide 0.28.0 identifier --- cibuildwheel/resources/build-platforms.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/cibuildwheel/resources/build-platforms.toml b/cibuildwheel/resources/build-platforms.toml index 7a5a7628e..0ab599570 100644 --- a/cibuildwheel/resources/build-platforms.toml +++ b/cibuildwheel/resources/build-platforms.toml @@ -222,6 +222,7 @@ python_configurations = [ python_configurations = [ { identifier = "cp312-pyodide_wasm32", version = "3.12", default_pyodide_version = "0.27.7", node_version = "v22" }, { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0a3", node_version = "v22" }, + { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0", node_version = "v22" }, ] [ios] From 381dbd54775f4ee8beff5ff7764aafbc634e7f05 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:10:03 +0530 Subject: [PATCH 04/15] Override to a different, alpha version for testing --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index eeac8ae92..f10ca7e54 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -244,7 +244,7 @@ jobs: env: CIBW_PLATFORM: pyodide CIBW_BUILD: "cp312*" - CIBW_PYODIDE_VERSION: "0.28.0" + CIBW_PYODIDE_VERSION: "0.28.0a3" - name: Run tests with 'CIBW_PLATFORM' set to 'pyodide' run: | From 3ebe89ed29f51c3b1f9f1a5440b2777f419a06d1 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:12:21 +0530 Subject: [PATCH 05/15] Update docs for Pyodide versions everywhere --- docs/options.md | 16 ++++++++-------- unit_test/options_test.py | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/docs/options.md b/docs/options.md index 6718c64fd..2da697f2a 100644 --- a/docs/options.md +++ b/docs/options.md @@ -1288,22 +1288,22 @@ The available Pyodide versions are determined by the version of `pyodide-build` ```toml [tool.cibuildwheel.pyodide] - # Build Pyodide wheels using Pyodide version 0.27.6 - pyodide-version = "0.27.6" + # Build Pyodide wheels using Pyodide version 0.28.0 + pyodide-version = "0.28.0" [tool.cibuildwheel.pyodide] - # Build Pyodide wheels using a specific alpha release - pyodide-version = "0.28.0a2" + # Build Pyodide wheels using a specific, previously released alpha release of 0.28.0 + pyodide-version = "0.28.0a3" ``` !!! tab examples "Environment variables" ```yaml - # Build Pyodide wheels using Pyodide version 0.27.6 - CIBW_PYODIDE_VERSION: 0.27.6 + # Build Pyodide wheels using Pyodide version 0.28.0 + CIBW_PYODIDE_VERSION: 0.28.0 - # Build Pyodide wheels using a specific alpha release - CIBW_PYODIDE_VERSION: 0.28.0a2 + # Build Pyodide wheels using a specific, previously released alpha release of 0.28.0 + CIBW_PYODIDE_VERSION: 0.28.0a3 ``` diff --git a/unit_test/options_test.py b/unit_test/options_test.py index 8bf7e5691..d1207aa15 100644 --- a/unit_test/options_test.py +++ b/unit_test/options_test.py @@ -35,7 +35,7 @@ environment-pass = ["EXAMPLE_ENV"] -pyodide-version = "0.27.6" +pyodide-version = "0.28.0" [tool.cibuildwheel.macos] test-requires = "else" @@ -92,7 +92,7 @@ def test_options_1(tmp_path, monkeypatch): assert local.manylinux_images["x86_64"] == pinned_x86_64_container_image["manylinux_2_34"] local = options.build_options("cp312-pyodide_wasm32") - assert local.pyodide_version == "0.27.6" + assert local.pyodide_version == "0.28.0" def test_passthrough(tmp_path, monkeypatch): From 5f329500af54ede3dfe5649c0b6c8e9c2d5a393e Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:13:21 +0530 Subject: [PATCH 06/15] Add comment on using older Pyodide alpha version --- .github/workflows/test.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f10ca7e54..fb7f7ca82 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -244,6 +244,8 @@ jobs: env: CIBW_PLATFORM: pyodide CIBW_BUILD: "cp312*" + # We don't have an alpha version for 0.29.0 yet, so we use the latest released + # alpha version that was available for 0.28.0. CIBW_PYODIDE_VERSION: "0.28.0a3" - name: Run tests with 'CIBW_PLATFORM' set to 'pyodide' From 7ac99678dec4ff93e1c47111db76516e5b79f547 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:17:59 +0530 Subject: [PATCH 07/15] Bump to `"cp313*"` for compatibility --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fb7f7ca82..a7b596437 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -243,7 +243,7 @@ jobs: # in cibuildwheel/resources/build-platforms.toml. env: CIBW_PLATFORM: pyodide - CIBW_BUILD: "cp312*" + CIBW_BUILD: "cp313*" # We don't have an alpha version for 0.29.0 yet, so we use the latest released # alpha version that was available for 0.28.0. CIBW_PYODIDE_VERSION: "0.28.0a3" From 3eb8d734da7c8bce4725469e208e6f6f91f923bd Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 11:24:11 +0530 Subject: [PATCH 08/15] Drop identifier for Pyodide 0.28.0a3 --- cibuildwheel/resources/build-platforms.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/cibuildwheel/resources/build-platforms.toml b/cibuildwheel/resources/build-platforms.toml index 0ab599570..b3c06e98d 100644 --- a/cibuildwheel/resources/build-platforms.toml +++ b/cibuildwheel/resources/build-platforms.toml @@ -221,7 +221,6 @@ python_configurations = [ [pyodide] python_configurations = [ { identifier = "cp312-pyodide_wasm32", version = "3.12", default_pyodide_version = "0.27.7", node_version = "v22" }, - { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0a3", node_version = "v22" }, { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0", node_version = "v22" }, ] From e616c3fe617c8c901c6db40eb3c3ed122aba0af4 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 12:11:19 +0530 Subject: [PATCH 09/15] Add back Pyodide 0.28.0a3 identifier --- cibuildwheel/resources/build-platforms.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/cibuildwheel/resources/build-platforms.toml b/cibuildwheel/resources/build-platforms.toml index b3c06e98d..0ab599570 100644 --- a/cibuildwheel/resources/build-platforms.toml +++ b/cibuildwheel/resources/build-platforms.toml @@ -221,6 +221,7 @@ python_configurations = [ [pyodide] python_configurations = [ { identifier = "cp312-pyodide_wasm32", version = "3.12", default_pyodide_version = "0.27.7", node_version = "v22" }, + { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0a3", node_version = "v22" }, { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0", node_version = "v22" }, ] From 5ee499bdd594dcf1558c8871a549e7fa2ba6cc5c Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 12:11:49 +0530 Subject: [PATCH 10/15] Add helpful comment about pyodide-prerelease option --- cibuildwheel/selector.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/cibuildwheel/selector.py b/cibuildwheel/selector.py index 256e4fb04..83031c041 100644 --- a/cibuildwheel/selector.py +++ b/cibuildwheel/selector.py @@ -99,10 +99,16 @@ def __call__(self, build_id: str) -> bool: return False if EnableGroup.GraalPy not in self.enable and fnmatch(build_id, "gp*"): return False - if EnableGroup.PyodidePrerelease not in self.enable and fnmatch( - build_id, "cp313-pyodide_*" - ): - return False + # TODO: Re-enable this when we have Pyodide prereleases again (e.g., 0.29.0a1+) + # Python 3.13 support became stable in Pyodide 0.28.0, so it no longer needs a prerelease + # flag. + # When re-enabling, update the pattern to match the experimental Python version in case + # it is bumped to Python 3.14 (likely cp314-pyodide_* but could remain as 3.13 as well). + # This depends on the CPython version being used in the Pyodide runtime at the time. + # if EnableGroup.PyodidePrerelease not in self.enable and fnmatch( + # build_id, "cp313-pyodide_*" + # ): + # return False should_build = selector_matches(self.build_config, build_id) should_skip = selector_matches(self.skip_config, build_id) From 6bf80273d0119f22bc758c79235429d90450f6e5 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 12:19:23 +0530 Subject: [PATCH 11/15] Fix test and add a comment about it --- cibuildwheel/selector.py | 1 + unit_test/build_selector_test.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/cibuildwheel/selector.py b/cibuildwheel/selector.py index 83031c041..f0bce928a 100644 --- a/cibuildwheel/selector.py +++ b/cibuildwheel/selector.py @@ -102,6 +102,7 @@ def __call__(self, build_id: str) -> bool: # TODO: Re-enable this when we have Pyodide prereleases again (e.g., 0.29.0a1+) # Python 3.13 support became stable in Pyodide 0.28.0, so it no longer needs a prerelease # flag. + # Also update Pyodide tests in unit_test/build_selector_test.py accordingly. # When re-enabling, update the pattern to match the experimental Python version in case # it is bumped to Python 3.14 (likely cp314-pyodide_* but could remain as 3.13 as well). # This depends on the CPython version being used in the Pyodide runtime at the time. diff --git a/unit_test/build_selector_test.py b/unit_test/build_selector_test.py index 601fe25f5..4c723244d 100644 --- a/unit_test/build_selector_test.py +++ b/unit_test/build_selector_test.py @@ -107,7 +107,7 @@ def test_build_filter_pyodide(): enable=frozenset(), ) assert build_selector("cp312-pyodide_wasm32") - assert not build_selector("cp313-pyodide_wasm32") + assert build_selector("cp313-pyodide_wasm32") def test_skip(): From 7e909d754183cc1ce5f1b8851992995b0f353d9b Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 12:30:36 +0530 Subject: [PATCH 12/15] Keep one Pyodide version per Python version --- cibuildwheel/resources/build-platforms.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/cibuildwheel/resources/build-platforms.toml b/cibuildwheel/resources/build-platforms.toml index 0ab599570..b3c06e98d 100644 --- a/cibuildwheel/resources/build-platforms.toml +++ b/cibuildwheel/resources/build-platforms.toml @@ -221,7 +221,6 @@ python_configurations = [ [pyodide] python_configurations = [ { identifier = "cp312-pyodide_wasm32", version = "3.12", default_pyodide_version = "0.27.7", node_version = "v22" }, - { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0a3", node_version = "v22" }, { identifier = "cp313-pyodide_wasm32", version = "3.13", default_pyodide_version = "0.28.0", node_version = "v22" }, ] From bda44b8879c623db3f1f4c4b5ec15b7e1a59d6b8 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Mon, 7 Jul 2025 12:35:33 +0530 Subject: [PATCH 13/15] =?UTF-8?q?Fix=20docs=20for=20`pyodide-prerelease`;?= =?UTF-8?q?=20Python=20=E2=9E=A1=EF=B8=8F=20Pyodide?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/platforms.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/platforms.md b/docs/platforms.md index 84a8cb502..17cc40a88 100644 --- a/docs/platforms.md +++ b/docs/platforms.md @@ -172,7 +172,7 @@ You must target pyodide with `--platform pyodide` (or use `--only` on the identi It is also possible to target a specific Pyodide version by setting the [`pyodide-version`](options.md#pyodide-version) option to the desired version. Users are responsible for setting an appropriate Pyodide version according to the `pyodide-build` version. A list is available in Pyodide's [cross-build environments metadata file](https://github.com/pyodide/pyodide/blob/main/pyodide-cross-build-environments.json), which can be viewed more easily by installing `pyodide-build` from PyPI and using `pyodide xbuildenv search --all` to see a compatibility table. -If there are pre-releases available for a newer Python version, the `pyodide-prerelease` [`enable`](options.md#enable) can be used to include pre-release versions. +If there are pre-releases available for a newer Pyodide version, the `pyodide-prerelease` [`enable`](options.md#enable) can be used to include pre-release versions. ### Running tests From 095176b1fd376f90b12db8c9e5cbc7aeab9af4f5 Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Wed, 9 Jul 2025 23:09:50 -0700 Subject: [PATCH 14/15] Update utils.py --- test/utils.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/test/utils.py b/test/utils.py index 749e54dc1..ccd467aa9 100644 --- a/test/utils.py +++ b/test/utils.py @@ -261,9 +261,7 @@ def _expected_wheels( musllinux_versions = ["musllinux_1_2"] if platform == "pyodide" and python_abi_tags is None: - python_abi_tags = ["cp312-cp312"] - if EnableGroup.PyodidePrerelease in enable_groups: - python_abi_tags.append("cp313-cp313") + python_abi_tags = ["cp312-cp312", "cp313-cp313"] elif platform == "ios" and python_abi_tags is None: python_abi_tags = ["cp313-cp313"] elif python_abi_tags is None: From b19e9dd94eb0136f6af7491e291512b343c295e3 Mon Sep 17 00:00:00 2001 From: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> Date: Thu, 10 Jul 2025 15:03:38 +0530 Subject: [PATCH 15/15] Drop CI test step for overridden Pyodide version Suggested-by: Joe Rickerby --- .github/workflows/test.yml | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a7b596437..229bce922 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -233,21 +233,6 @@ jobs: env: CIBW_PLATFORM: pyodide - - name: Run a sample build (GitHub Action) for an overridden Pyodide version - uses: ./ - with: - package-dir: sample_proj - output-dir: wheelhouse - # In case this breaks at any point in time, switch to using the latest version - # available or any other version that is not the same as the default one set - # in cibuildwheel/resources/build-platforms.toml. - env: - CIBW_PLATFORM: pyodide - CIBW_BUILD: "cp313*" - # We don't have an alpha version for 0.29.0 yet, so we use the latest released - # alpha version that was available for 0.28.0. - CIBW_PYODIDE_VERSION: "0.28.0a3" - - name: Run tests with 'CIBW_PLATFORM' set to 'pyodide' run: | uv run --no-sync ./bin/run_tests.py