fix: raise clear errors when no wheel is produced (#2909)

This commit is contained in:
Henry Schreiner
2026-06-12 17:22:07 +05:30
committed by GitHub
parent f3aa1bed4f
commit 4f42ee3f03
7 changed files with 54 additions and 8 deletions
+4 -1
View File
@@ -522,7 +522,10 @@ def build(options: Options, tmp_path: Path) -> None:
case _:
assert_never(build_frontend)
built_wheel = next(built_wheel_dir.glob("*.whl"))
try:
built_wheel = next(built_wheel_dir.glob("*.whl"))
except StopIteration:
raise errors.BuildProducedNoWheelError() from None
# repair the wheel
repaired_wheel_dir.mkdir()