Skip to content

Commit d16fda1

Browse files
committed
drop warning on unused riscv64 enable option
1 parent 80e5e25 commit d16fda1

File tree

3 files changed

+1
-73
lines changed

3 files changed

+1
-73
lines changed

cibuildwheel/__main__.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -463,13 +463,6 @@ def detect_warnings(*, options: Options) -> Generator[str, None, None]:
463463
build_selector = options.globals.build_selector
464464
test_selector = options.globals.test_selector
465465

466-
if EnableGroup.CPythonExperimentalRiscV64 in build_selector.enable:
467-
yield (
468-
"'cpython-experimental-riscv64' enable is deprecated and will be removed in a future version. "
469-
"It should be removed from tool.cibuildwheel.enable in pyproject.toml "
470-
"or CIBW_ENABLE environment variable."
471-
)
472-
473466
all_valid_identifiers = [
474467
config.identifier
475468
for module in ALL_PLATFORM_MODULES.values()

cibuildwheel/selector.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class EnableGroup(StrEnum):
3838

3939
@classmethod
4040
def all_groups(cls) -> frozenset["EnableGroup"]:
41-
return frozenset(set(cls) - {cls.CPythonExperimentalRiscV64})
41+
return frozenset(cls)
4242

4343
@classmethod
4444
def parse_option_value(cls, value: str) -> frozenset["EnableGroup"]:

unit_test/main_tests/main_options_test.py

Lines changed: 0 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import os
21
import sys
32
import tomllib
43
from fnmatch import fnmatch
@@ -142,70 +141,6 @@ def test_empty_selector(monkeypatch):
142141
assert e.value.code == 3
143142

144143

145-
@pytest.mark.usefixtures("platform", "intercepted_build_args")
146-
def test_riscv64_warning1(monkeypatch, capsys):
147-
monkeypatch.setenv("CIBW_ENABLE", "cpython-experimental-riscv64")
148-
149-
main()
150-
151-
_, err = capsys.readouterr()
152-
print(err)
153-
assert "'cpython-experimental-riscv64' enable is deprecated" in err
154-
155-
156-
@pytest.mark.usefixtures("platform", "intercepted_build_args")
157-
def test_riscv64_warning2(monkeypatch, capsys, tmp_path):
158-
local_path = tmp_path / "tmp_project"
159-
os.mkdir(local_path) # noqa:PTH102 Path.mkdir has been monkeypatched already
160-
local_path.joinpath("setup.py").touch()
161-
162-
monkeypatch.setattr(
163-
sys, "argv", ["cibuildwheel", "--only", "cp313-manylinux_riscv64", str(local_path)]
164-
)
165-
monkeypatch.setenv("CIBW_ENABLE", "cpython-experimental-riscv64")
166-
167-
main()
168-
169-
_, err = capsys.readouterr()
170-
print(err)
171-
assert "'cpython-experimental-riscv64' enable is deprecated" in err
172-
173-
174-
@pytest.mark.usefixtures("platform", "intercepted_build_args")
175-
def test_riscv64_no_warning(monkeypatch, capsys, tmp_path):
176-
local_path = tmp_path / "tmp_project"
177-
os.mkdir(local_path) # noqa:PTH102 Path.mkdir has been monkeypatched already
178-
local_path.joinpath("setup.py").touch()
179-
180-
monkeypatch.setattr(
181-
sys, "argv", ["cibuildwheel", "--only", "cp313-manylinux_riscv64", str(local_path)]
182-
)
183-
184-
main()
185-
186-
_, err = capsys.readouterr()
187-
print(err)
188-
assert "'cpython-experimental-riscv64' enable is deprecated" not in err
189-
190-
191-
@pytest.mark.usefixtures("platform", "intercepted_build_args")
192-
def test_riscv64_no_warning2(monkeypatch, capsys, tmp_path):
193-
local_path = tmp_path / "tmp_project"
194-
os.mkdir(local_path) # noqa:PTH102 Path.mkdir has been monkeypatched already
195-
local_path.joinpath("setup.py").touch()
196-
197-
monkeypatch.setattr(
198-
sys, "argv", ["cibuildwheel", "--only", "cp313-manylinux_riscv64", str(local_path)]
199-
)
200-
monkeypatch.setenv("CIBW_ENABLE", "all")
201-
202-
main()
203-
204-
_, err = capsys.readouterr()
205-
print(err)
206-
assert "'cpython-experimental-riscv64' enable is deprecated" not in err
207-
208-
209144
@pytest.mark.parametrize(
210145
("architecture", "image", "full_image"),
211146
[

0 commit comments

Comments
 (0)