feat: drop python3.13t (#2684)

* break: remove cp313t

* break: drop unused cpython-freethreading enable option

* update message
This commit is contained in:
Matthieu Darbois
2026-05-09 10:59:24 -04:00
committed by GitHub
parent b425e9d2a7
commit 542335fb4a
18 changed files with 39 additions and 226 deletions
-45
View File
@@ -18,7 +18,6 @@ from cibuildwheel.options import (
_get_pinned_container_images,
)
from cibuildwheel.platforms import ALL_PLATFORM_MODULES, get_build_identifiers
from cibuildwheel.selector import EnableGroup
from cibuildwheel.util import resources
from cibuildwheel.util.packaging import DependencyConstraints
@@ -446,50 +445,6 @@ def test_override_inherit_environment_with_references(tmp_path: Path) -> None:
}
@pytest.mark.parametrize(
("toml_assignment", "env", "enable_args", "expected_result"),
[
("", {}, [], False),
("enable = ['cpython-freethreading']", {}, [], True),
("enable = []", {}, [], False),
("", {}, ["cpython-freethreading"], True),
("", {}, ["cpython-freethreading", "pypy"], True),
("", {"CIBW_ENABLE": "pypy"}, [], False),
("", {"CIBW_ENABLE": "cpython-freethreading"}, [], True),
("enable = []", {"CIBW_ENABLE": "cpython-freethreading"}, [], True),
("enable = ['cpython-freethreading']", {"CIBW_ENABLE": "pypy"}, [], True),
("enable = ['cpython-freethreading']", {}, ["pypy"], True),
("enable = ['cpython-freethreading']", {"CIBW_ENABLE": ""}, [], True),
("enable = []", {"CIBW_ENABLE": ""}, [], False),
],
)
def test_free_threaded_support(
tmp_path: Path,
toml_assignment: str,
env: dict[str, str],
enable_args: list[str],
expected_result: bool,
) -> None:
args = CommandLineArguments.defaults()
args.package_dir = tmp_path
args.enable = enable_args
pyproject_toml: Path = tmp_path / "pyproject.toml"
pyproject_toml.write_text(
textwrap.dedent(
f"""\
[tool.cibuildwheel]
{toml_assignment}
"""
)
)
options = Options(platform="linux", command_line_arguments=args, env=env)
if expected_result:
assert EnableGroup.CPythonFreeThreading in options.globals.build_selector.enable
else:
assert EnableGroup.CPythonFreeThreading not in options.globals.build_selector.enable
@pytest.mark.parametrize(
("toml_assignment", "base_file_path", "packages"),
[