Skip to content

feat: Python 3.14rc1 build by default #2507

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 24, 2025
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ While cibuildwheel itself requires a recent Python version to run (we support th
| CPython 3.11 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | ✅⁵ | N/A | N/A |
| CPython 3.12 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | ✅⁵ | N/A | ✅⁴ |
| CPython 3.13³ | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | ✅⁵ | ✅ | N/A |
| CPython 3.14³ | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | ✅⁵ | ✅ | N/A |
| CPython 3.14 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | ✅⁵ | ✅ | N/A |
| PyPy 3.8 v7.3 | ✅ | ✅ | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A | N/A | N/A | N/A |
| PyPy 3.9 v7.3 | ✅ | ✅ | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A | N/A | N/A | N/A |
| PyPy 3.10 v7.3 | ✅ | ✅ | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A | N/A | N/A | N/A |
Expand All @@ -40,7 +40,7 @@ While cibuildwheel itself requires a recent Python version to run (we support th

<sup>¹ PyPy & GraalPy are only supported for manylinux wheels.</sup><br>
<sup>² Windows arm64 support is experimental.</sup><br>
<sup>³ Free-threaded mode requires opt-in using [`enable`](https://cibuildwheel.pypa.io/en/stable/options/#enable).</sup><br>
<sup>³ Free-threaded mode requires opt-in on 3.13 using [`enable`](https://cibuildwheel.pypa.io/en/stable/options/#enable).</sup><br>
<sup>⁴ Experimental, not yet supported on PyPI, but can be used directly in web deployment. Use `--platform pyodide` to build.</sup><br>
<sup>⁵ manylinux armv7l support is experimental. As there are no RHEL based image for this architecture, it's using an Ubuntu based image instead.</sup><br>

Expand Down
24 changes: 12 additions & 12 deletions cibuildwheel/resources/build-platforms.toml
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,12 @@ python_configurations = [
{ identifier = "cp313t-macosx_x86_64", version = "3.13", url = "https://www.python.org/ftp/python/3.13.5/python-3.13.5-macos11.pkg" },
{ identifier = "cp313t-macosx_arm64", version = "3.13", url = "https://www.python.org/ftp/python/3.13.5/python-3.13.5-macos11.pkg" },
{ identifier = "cp313t-macosx_universal2", version = "3.13", url = "https://www.python.org/ftp/python/3.13.5/python-3.13.5-macos11.pkg" },
{ identifier = "cp314-macosx_x86_64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314-macosx_arm64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314-macosx_universal2", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314t-macosx_x86_64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314t-macosx_arm64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314t-macosx_universal2", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0b4-macos11.pkg" },
{ identifier = "cp314-macosx_x86_64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "cp314-macosx_arm64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "cp314-macosx_universal2", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "cp314t-macosx_x86_64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "cp314t-macosx_arm64", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "cp314t-macosx_universal2", version = "3.14", url = "https://www.python.org/ftp/python/3.14.0/python-3.14.0rc1-macos11.pkg" },
{ identifier = "pp38-macosx_x86_64", version = "3.8", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.11-macos_x86_64.tar.bz2" },
{ identifier = "pp38-macosx_arm64", version = "3.8", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.11-macos_arm64.tar.bz2" },
{ identifier = "pp39-macosx_x86_64", version = "3.9", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.16-macos_x86_64.tar.bz2" },
Expand Down Expand Up @@ -199,18 +199,18 @@ python_configurations = [
{ identifier = "cp313t-win32", version = "3.13.5", arch = "32" },
{ identifier = "cp313-win_amd64", version = "3.13.5", arch = "64" },
{ identifier = "cp313t-win_amd64", version = "3.13.5", arch = "64" },
{ identifier = "cp314-win32", version = "3.14.0-b4", arch = "32" },
{ identifier = "cp314t-win32", version = "3.14.0-b4", arch = "32" },
{ identifier = "cp314-win_amd64", version = "3.14.0-b4", arch = "64" },
{ identifier = "cp314t-win_amd64", version = "3.14.0-b4", arch = "64" },
{ identifier = "cp314-win32", version = "3.14.0-rc1", arch = "32" },
{ identifier = "cp314t-win32", version = "3.14.0-rc1", arch = "32" },
{ identifier = "cp314-win_amd64", version = "3.14.0-rc1", arch = "64" },
{ identifier = "cp314t-win_amd64", version = "3.14.0-rc1", arch = "64" },
{ identifier = "cp39-win_arm64", version = "3.9.10", arch = "ARM64" },
{ identifier = "cp310-win_arm64", version = "3.10.11", arch = "ARM64" },
{ identifier = "cp311-win_arm64", version = "3.11.9", arch = "ARM64" },
{ identifier = "cp312-win_arm64", version = "3.12.10", arch = "ARM64" },
{ identifier = "cp313-win_arm64", version = "3.13.5", arch = "ARM64" },
{ identifier = "cp313t-win_arm64", version = "3.13.5", arch = "ARM64" },
{ identifier = "cp314-win_arm64", version = "3.14.0-b4", arch = "ARM64" },
{ identifier = "cp314t-win_arm64", version = "3.14.0-b4", arch = "ARM64" },
{ identifier = "cp314-win_arm64", version = "3.14.0-rc1", arch = "ARM64" },
{ identifier = "cp314t-win_arm64", version = "3.14.0-rc1", arch = "ARM64" },
{ identifier = "pp38-win_amd64", version = "3.8", arch = "64", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.11-win64.zip" },
{ identifier = "pp39-win_amd64", version = "3.9", arch = "64", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.16-win64.zip" },
{ identifier = "pp310-win_amd64", version = "3.10", arch = "64", url = "https://downloads.python.org/pypy/pypy3.10-v7.3.19-win64.zip" },
Expand Down
66 changes: 33 additions & 33 deletions cibuildwheel/resources/pinned_docker_images.cfg
Original file line number Diff line number Diff line change
@@ -1,53 +1,53 @@
[x86_64]
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_x86_64:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_x86_64:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_x86_64:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_x86_64:2025.07.23-1

[i686]
manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_i686:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_i686:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_i686:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_i686:2025.07.23-1

[aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_aarch64:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_aarch64:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_aarch64:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_aarch64:2025.07.23-1

[ppc64le]
manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_ppc64le:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_ppc64le:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_ppc64le:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_ppc64le:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_ppc64le:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_ppc64le:2025.07.23-1

[s390x]
manylinux2014 = quay.io/pypa/manylinux2014_s390x:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_s390x:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_s390x:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_s390x:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_s390x:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_s390x:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_s390x:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_s390x:2025.07.23-1

[pypy_x86_64]
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_x86_64:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_x86_64:2025.07.23-1

[pypy_i686]
manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_i686:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_i686:2025.07.23-1

[pypy_aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2025.07.20-2
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2025.07.20-2
manylinux_2_34 = quay.io/pypa/manylinux_2_34_aarch64:2025.07.20-2
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2025.07.23-1
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2025.07.23-1
manylinux_2_34 = quay.io/pypa/manylinux_2_34_aarch64:2025.07.23-1

[armv7l]
manylinux_2_31 = quay.io/pypa/manylinux_2_31_armv7l:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_armv7l:2025.07.20-2
manylinux_2_31 = quay.io/pypa/manylinux_2_31_armv7l:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_armv7l:2025.07.23-1

[riscv64]
manylinux_2_39 = quay.io/pypa/manylinux_2_39_riscv64:2025.07.20-2
musllinux_1_2 = quay.io/pypa/musllinux_1_2_riscv64:2025.07.20-2
manylinux_2_39 = quay.io/pypa/manylinux_2_39_riscv64:2025.07.23-1
musllinux_1_2 = quay.io/pypa/musllinux_1_2_riscv64:2025.07.23-1

2 changes: 1 addition & 1 deletion cibuildwheel/selector.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ def __call__(self, build_id: str) -> bool:
# filter out groups that are not enabled
if EnableGroup.CPythonFreeThreading not in self.enable and fnmatch(build_id, "cp313t-*"):
return False
Comment on lines 88 to 89
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if there was any discussion about it already. Should cp314t really be build by default? I'm not involved enough in the free threading ecosystem to know the current state of things. At least for mypy, I'd probably need to disable the builds manually to get the build pipeline to pass if the PR is merged as is.

The enable = ["cpython-freethreading"] option feels safer at least for the moment.

Copy link
Contributor

@henryiii henryiii Jul 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Starting with CPython 3.14 beta 3, free-threading is no longer experimental. That means every package should strive to produce free-threading wheels, and they should opt out rather than opt in, unlike 3.13. We only had the enable while it was experimental ("This will enable building these wheels while they are experimental." was the exact quote in our docs). We turned this off in a previous PR #2503, and that’s where you can see the text about this only being true while experimental. https://peps.python.org/pep-0779/

I think it's fine if you have to turn it off, you are explicitly stating you don't fully support all of 3.14. Most binding tools (pybind11, nanobind, cython, SWIG, PyO3, see https://py-free-threading.github.io/tracking/) have supported free threading for quite a while. MyPyC is one of the largest ones that doesn't, I think.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I did see that it's no longer considered experimental. Though I'd say that mainly applies for cpython itself. Not sure how far along the ecosystem itself is / how challenging it is to get the free threading builds to pass.

I'd suspect this will probably take another year or two, at least.

Copy link
Contributor

@henryiii henryiii Jul 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but hopefully this will push people to start supporting it if they aren't already. The next stage will require most packages to support it, and I think the point of declaring it no longer experimental upstream is to signal that you can't just ignore it anymore downstream, which is also what we are also doing by requiring it to be explicitly skipped. Plus we explicitly said the enable was only going to be valid while it was experimental upstream. :)

We used to require PyPy be explicitly skipped, and we still require musllinux to be explicitly skipped, so we have a bit of a history of requiring skips. :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Getting free threading working hasn't been that bad, though mostly people like @ngoldbaum and @colesbury have done a hero's share of the work, so maybe I shouldn't claim anything about how hard it was. ;) I'd guess it's not that bad for MyPyC, especially if you just supported 3.14t+, which is a little easier.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'd love to chat about adding support for free-threading in MyPyC.

I did the lion's share of the work for NumPy and PyO3 and our team has been involved in updating Cython, CFFI, SWIG and many other packages across the ecosystem. There's also the guide we're maintaining at https://py-free-threading.github.io.

All that to say we've accumulated a fair bit of know-how for this and we'd very much like to help out with MyPyC. In almost all cases we've looked at so far the issues have been more tractable than people initially feared.

Copy link

@cdce8p cdce8p Jul 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I suspected at least for mypy there were quite a few build errors. This is just from a test run: https://github.com/cdce8p/mypy_mypyc-wheels/actions/runs/16496179019/job/46642337801#step:4:4390.

We'd love to chat about adding support for free-threading in MyPyC.

This isn't my area of expertise per se. Feel free to engage on the issue tracker though. I believe this is the relevant issue for it: mypyc/mypyc#1038.

Copy link

@cdce8p cdce8p Jul 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To add one more datapoint only because I saw it just now: The dependabot update compatibility for cibuildwheel is at 33% currently. Obviously it's difficult to tell if that's because of 314, free threading or a combination of both.

Anyway the release notes make it quite obvious how to disable it so it isn't really an issue.

if EnableGroup.CPythonPrerelease not in self.enable and fnmatch(build_id, "cp314*"):
if EnableGroup.CPythonPrerelease not in self.enable and fnmatch(build_id, "cp315*"):
return False
if EnableGroup.PyPy not in self.enable and fnmatch(build_id, "pp31*"):
return False
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ py-version = "3.11"
jobs = "0"
fail-on = ["E", "F"]
fail-under = "9.8"
max-positional-arguments = "7"
reports.output-format = "colorized"
messages_control.enable = [
"useless-suppression",
Expand Down
5 changes: 3 additions & 2 deletions test/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,15 +272,16 @@ def _expected_wheels(
"cp311-cp311",
"cp312-cp312",
"cp313-cp313",
"cp314-cp314",
"cp314-cp314t",
]

enable_groups = get_enable_groups()
if EnableGroup.CPythonFreeThreading in enable_groups:
python_abi_tags.append("cp313-cp313t")

if EnableGroup.CPythonPrerelease in enable_groups:
python_abi_tags.append("cp314-cp314")
python_abi_tags.append("cp314-cp314t")
... # Add cp315 here when available

if EnableGroup.PyPyEoL in enable_groups:
python_abi_tags += [
Expand Down
2 changes: 2 additions & 0 deletions unit_test/build_selector_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def test_build():
assert build_selector("cp311-manylinux_x86_64")
assert build_selector("cp312-manylinux_x86_64")
assert build_selector("cp313-manylinux_x86_64")
assert build_selector("cp314-manylinux_x86_64")
assert build_selector("pp310-manylinux_x86_64")
assert build_selector("pp311-manylinux_x86_64")
assert build_selector("cp36-manylinux_i686")
Expand All @@ -36,6 +37,7 @@ def test_build():
assert build_selector("cp311-win_amd64")
assert build_selector("cp312-win_amd64")
assert build_selector("cp313-win_amd64")
assert build_selector("cp314-win_amd64")
assert not build_selector("pp310-win_amd64")
assert not build_selector("pp311-win_amd64")

Expand Down
6 changes: 4 additions & 2 deletions unit_test/linux_build_steps_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ def container_engines(
"cp311-manylinux_x86_64",
"cp312-manylinux_x86_64",
"cp313-manylinux_x86_64",
"cp314-manylinux_x86_64",
"cp314t-manylinux_x86_64",
]
assert before_alls(build_steps[3]) == [""] * 3
assert container_engines(build_steps[3]) == [default_container_engine] * 3
assert before_alls(build_steps[3]) == [""] * 5
assert container_engines(build_steps[3]) == [default_container_engine] * 5
6 changes: 5 additions & 1 deletion unit_test/option_prepare_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
from cibuildwheel.oci_container import OCIPlatform
from cibuildwheel.util import file

DEFAULT_IDS = {"cp38", "cp39", "cp310", "cp311", "cp312", "cp313"}
DEFAULT_IDS = {"cp38", "cp39", "cp310", "cp311", "cp312", "cp313", "cp314", "cp314t"}
ALL_IDS = DEFAULT_IDS | {"cp313t", "pp38", "pp39", "pp310", "pp311", "gp311_242"}


Expand Down Expand Up @@ -155,6 +155,8 @@ def test_build_with_override_launches(monkeypatch, tmp_path):
"cp312",
"cp313",
"cp313t",
"cp314",
"cp314t",
"pp38",
"pp39",
"pp310",
Expand All @@ -177,6 +179,8 @@ def test_build_with_override_launches(monkeypatch, tmp_path):
"cp312",
"cp313",
"cp313t",
"cp314",
"cp314t",
"pp38",
"pp39",
"pp310",
Expand Down
Loading