Compare commits

...
18 Commits
Author SHA1 Message Date
Joe Rickerby 7c45799919 Bump version: v2.10.2 2022-09-25 09:48:12 +01:00
Joe Rickerby f7669045f5 Merge pull request #1258 from henryiii/henryiii/chore/dev
chore: nicer tracebacks and dev improvements
2022-09-25 09:34:05 +01:00
Joe Rickerby 73a435b9f6 Merge pull request #1266 from henryiii/henryiii/fix/crossplatform
fix: better cross-platform auto archs
2022-09-25 09:31:25 +01:00
Joe Rickerby 8b0aa9b9e5 Merge pull request #1282 from pypa/fix-1281 2022-09-25 08:33:28 +01:00
Joe Rickerby 6b0e1bc2c4 Merge pull request #1274 from pypa/diagram-fix 2022-09-25 08:32:16 +01:00
Joe Rickerby 5e5fdd1b9a Fix win32 identifiers with --only 2022-09-24 23:12:32 +01:00
Joe Rickerby 1e3f3fdce7 Add failing test 2022-09-24 23:10:05 +01:00
Joe Rickerby faa3ab4c2a Refactor a little to minimise changes and clarify naming 2022-09-24 23:04:46 +01:00
cibuildwheel-bot[bot]andcibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com> 7969f7c794 [Bot] Update dependencies (#1275)
Update dependencies

Co-authored-by: cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>
2022-09-20 13:34:54 -04:00
Joe Rickerby 4447618234 Merge pull request #1276 from pypa/pre-commit-ci-update-config 2022-09-19 22:14:49 +01:00
pre-commit-ci[bot] 747b9d013b [pre-commit.ci] pre-commit autoupdate
updates:
- [github.com/asottile/pyupgrade: v2.37.3 → v2.38.0](https://github.com/asottile/pyupgrade/compare/v2.37.3...v2.38.0)
2022-09-19 19:59:06 +00:00
Joe Rickerby 728e37103b Add script to generate the image from HTML 2022-09-18 16:12:57 +01:00
Joe Rickerby 4503076c80 Fix diagram venv box location
The repair step isn't done inside the test venv.
2022-09-18 13:46:49 +01:00
Henry SchreinerandJoe Rickerby c302a1d7f9 Apply suggestions from code review
Co-authored-by: Joe Rickerby <joerick@mac.com>
2022-09-16 11:05:35 -04:00
Henry Schreiner 534cada6a5 chore: cleaner exception tracebacks
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-09-16 11:05:35 -04:00
Henry Schreiner 929ecac7f8 chore(bin): remove ghapi requirement
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-09-16 11:05:35 -04:00
Henry Schreiner 505207c39b chore: drop [all] extra
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-09-16 11:05:35 -04:00
Henry Schreiner 6df5de7175 fix: better cross-platform auto archs
This improves the default arch selection when targetting a different platform.

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-09-12 23:44:33 -04:00
47 changed files with 446 additions and 241 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ repos:
- id: trailing-whitespace - id: trailing-whitespace
- repo: https://github.com/asottile/pyupgrade - repo: https://github.com/asottile/pyupgrade
rev: v2.37.3 rev: v2.38.0
hooks: hooks:
- id: pyupgrade - id: pyupgrade
args: ["--py37-plus"] args: ["--py37-plus"]
+9 -14
View File
@@ -92,7 +92,7 @@ jobs:
- uses: actions/setup-python@v3 - uses: actions/setup-python@v3
- name: Install cibuildwheel - name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.10.1 run: python -m pip install cibuildwheel==2.10.2
- name: Build wheels - name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse run: python -m cibuildwheel --output-dir wheelhouse
@@ -208,6 +208,14 @@ Changelog
<!-- this section was generated by bin/update_readme_changelog.py -- do not edit manually --> <!-- this section was generated by bin/update_readme_changelog.py -- do not edit manually -->
### v2.10.2
_25 September 2022_
- 🐛 Fix a bug that caused `win32` identifiers to fail when used with `--only`. (#1282)
- 🐛 Fix computation of `auto`/`auto64`/`auto32` archs when targeting a different platform to the one that you're running cibuildwheel on. (#1266)
- 📚 Fix an mistake in the 'how it works' diagram. (#1274)
### v2.10.1 ### v2.10.1
_18 September 2022_ _18 September 2022_
@@ -244,19 +252,6 @@ _18 July 2022_
- 🛠 The GitHub Action will ensure a compatible version of Python is installed on the runner (#1114) - 🛠 The GitHub Action will ensure a compatible version of Python is installed on the runner (#1114)
- 📚 A few docs improvements - 📚 A few docs improvements
### v2.8.0
_5 July 2022_
- ✨ You can now run cibuildwheel on Podman, as an alternate container engine to Docker (which remains the default). This is useful in environments where a Docker daemon isn't available, for example, it can be run inside a Docker container, or without root access. To use Podman, set the [`CIBW_CONTAINER_ENGINE`](https://cibuildwheel.readthedocs.io/en/stable/options/#container-engine) option. (#966)
- ✨ Adds support for building `py3-none-{platform}` wheels. This works the same as ABI3 - wheels won't be rebuilt, but tests will still be run across all selected versions of Python.
> These wheels contain native extension code, but don't use the Python APIs. Typically, they're bridged to Python using a FFI module like [ctypes](https://docs.python.org/3/library/ctypes.html) or [cffi](https://cffi.readthedocs.io/en/latest/). Because they don't use Python ABI, the wheels are more compatible - they work across many Python versions.
Check out this [example ctypes project](https://github.com/joerick/python-ctypes-package-sample) to see an example of how it works. (#1151)
- 🛠 cibuildwheel will now error if multiple builds in a single run produce the same wheel filename, as this indicates a misconfiguration. (#1152)
- 📚 A few docs improvements and updates to keep things up-to-date.
<!-- END bin/update_readme_changelog.py --> <!-- END bin/update_readme_changelog.py -->
--- ---
+33 -15
View File
@@ -1,4 +1,17 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
"""
Check known projects for usage of requires-python.
Usage:
./bin/inspect_all_known_projects.py --online=$GITHUB_TOKEN
This will cache the results to all_known_setup.yaml; you can reprint
the results without the `--online` setting.
"""
from __future__ import annotations from __future__ import annotations
import ast import ast
@@ -7,7 +20,7 @@ from typing import Iterator
import click import click
import yaml import yaml
from ghapi.core import GhApi, HTTP404NotFoundError from github import Github, GithubException
from rich import print from rich import print
from cibuildwheel.projectfiles import Analyzer from cibuildwheel.projectfiles import Analyzer
@@ -47,33 +60,38 @@ def check_repo(name: str, contents: str) -> str:
class MaybeRemote: class MaybeRemote:
def __init__(self, cached_file: Path | str, *, online: bool) -> None: github: Github | None
self.online = online contents: dict[str, dict[str, str | None]]
if self.online:
self.contents: dict[str, dict[str, str | None]] = { def __init__(self, cached_file: Path | str, *, online: str | None) -> None:
if online is not None:
self.github = Github(online)
self.contents = {
"setup.py": {}, "setup.py": {},
"setup.cfg": {}, "setup.cfg": {},
"pyproject.toml": {}, "pyproject.toml": {},
} }
else: else:
self.github = None
with open(cached_file) as f: with open(cached_file) as f:
self.contents = yaml.safe_load(f) self.contents = yaml.safe_load(f)
def get(self, repo: str, filename: str) -> str | None: def get(self, repo: str, filename: str) -> str | None:
if self.online: if self.github:
try: try:
self.contents[filename][repo] = ( gh_file = self.github.get_repo(repo).get_contents(filename)
GhApi(*repo.split("/")).get_content(filename).decode() except GithubException:
)
except HTTP404NotFoundError:
self.contents[filename][repo] = None self.contents[filename][repo] = None
else:
assert not isinstance(gh_file, list)
self.contents[filename][repo] = gh_file.decoded_content.decode(encoding="utf-8")
return self.contents[filename][repo] return self.contents[filename][repo]
elif repo in self.contents[filename]: elif repo in self.contents[filename]:
return self.contents[filename][repo] return self.contents[filename][repo]
else: else:
raise RuntimeError( msg = f"Trying to access {repo}:{filename} and not in cache, rebuild cache"
f"Trying to access {repo}:{filename} and not in cache, rebuild cache" raise RuntimeError(msg)
)
def save(self, filename: Path | str) -> None: def save(self, filename: Path | str) -> None:
with open(filename, "w") as f: with open(filename, "w") as f:
@@ -87,8 +105,8 @@ class MaybeRemote:
@click.command() @click.command()
@click.option("--online", is_flag=True, help="Remember to set GITHUB_TOKEN") @click.option("--online", help="Set to $GITHUB_TOKEN")
def main(online: bool) -> None: def main(online: str | None) -> None:
with open(DIR / "../docs/data/projects.yml") as f: with open(DIR / "../docs/data/projects.yml") as f:
known = yaml.safe_load(f) known = yaml.safe_load(f)
+4 -2
View File
@@ -81,7 +81,8 @@ def ci_service_for_config_file(config_file):
if service.name == service_name: if service.name == service_name:
return service return service
raise ValueError(f"unknown ci service for config file {config_file}") msg = f"unknown ci service for config file {config_file}"
raise ValueError(msg)
@click.command() @click.command()
@@ -100,7 +101,8 @@ def run_example_ci_configs(config_files=None):
for config_file in config_files: for config_file in config_files:
service = ci_service_for_config_file(config_file) service = ci_service_for_config_file(config_file)
if service.name in configs_by_service: if service.name in configs_by_service:
raise Exception("You cannot specify more than one config per CI service") msg = "You cannot specify more than one config per CI service"
raise Exception(msg)
configs_by_service[service.name] = config_file configs_by_service[service.name] = config_file
if git_repo_has_changes(): if git_repo_has_changes():
+52
View File
@@ -0,0 +1,52 @@
#!/usr/bin/env python3
from __future__ import annotations
import subprocess
import sys
from pathlib import Path
try:
from html2image import Html2Image # type: ignore[import]
except ImportError:
sys.exit(
"""
html2image not found. Ensure you have Chrome (on Mac/Windows) or
Chromium (on Linux) installed, and then do:
pip install html2image
"""
)
def main():
subprocess.run(["mkdocs", "build"])
hti = Html2Image(custom_flags=["--force-device-scale-factor=2"])
html_str = Path("docs/diagram.md").read_text()
css_tags = f"""
<style>{Path("site/css/theme.css").read_text()}</style>
<style>{Path("site/css/theme_extra.css").read_text()}</style>
<style>{Path("site/extra.css").read_text()}</style>
<style>
body {{
background: white;
}}
</style>
"""
html_str = css_tags + html_str
[screenshot, *_] = hti.screenshot(
html_str=html_str,
size=(830, 405),
)
dest_path = Path("docs/data/how-it-works.png")
if dest_path.exists():
dest_path.unlink()
Path(screenshot).rename(dest_path)
if __name__ == "__main__":
main()
+6 -3
View File
@@ -141,7 +141,8 @@ class PyPyVersions:
releases = [r for r in releases if self.get_arch_file(r)] releases = [r for r in releases if self.get_arch_file(r)]
if not releases: if not releases:
raise RuntimeError(f"PyPy Win {self.arch} not found for {spec}! {self.releases}") msg = f"PyPy Win {self.arch} not found for {spec}! {self.releases}"
raise RuntimeError(msg)
version_arch = "win32" if self.arch == "32" else "win_amd64" version_arch = "win32" if self.arch == "32" else "win_amd64"
@@ -159,13 +160,15 @@ class PyPyVersions:
def update_version_macos(self, spec: Specifier) -> ConfigMacOS: def update_version_macos(self, spec: Specifier) -> ConfigMacOS:
if self.arch != "64": if self.arch != "64":
raise RuntimeError("Other archs not supported yet on macOS") msg = "Other archs not supported yet on macOS"
raise RuntimeError(msg)
releases = [r for r in self.releases if spec.contains(r["python_version"])] releases = [r for r in self.releases if spec.contains(r["python_version"])]
releases = sorted(releases, key=lambda r: r["pypy_version"]) # type: ignore[no-any-return] releases = sorted(releases, key=lambda r: r["pypy_version"]) # type: ignore[no-any-return]
if not releases: if not releases:
raise RuntimeError(f"PyPy macOS {self.arch} not found for {spec}!") msg = f"PyPy macOS {self.arch} not found for {spec}!"
raise RuntimeError(msg)
release = releases[-1] release = releases[-1]
version = release["python_version"] version = release["python_version"]
+1 -1
View File
@@ -1,3 +1,3 @@
from __future__ import annotations from __future__ import annotations
__version__ = "2.10.1" __version__ = "2.10.2"
+3 -2
View File
@@ -149,7 +149,8 @@ def main() -> None:
try: try:
(project_dir,) = temp_dir.iterdir() (project_dir,) = temp_dir.iterdir()
except ValueError: except ValueError:
raise SystemExit("invalid sdist: didn't contain a single dir") from None msg = "invalid sdist: didn't contain a single dir"
raise SystemExit(msg) from None
# This is now the new package dir # This is now the new package dir
args.package_dir = project_dir.resolve() args.package_dir = project_dir.resolve()
@@ -173,7 +174,7 @@ def build_in_directory(args: CommandLineArguments) -> None:
platform = "linux" platform = "linux"
elif "macosx_" in args.only: elif "macosx_" in args.only:
platform = "macos" platform = "macos"
elif "win_" in args.only: elif "win_" in args.only or "win32" in args.only:
platform = "windows" platform = "windows"
else: else:
print( print(
+33 -3
View File
@@ -3,12 +3,19 @@ from __future__ import annotations
import functools import functools
import platform as platform_module import platform as platform_module
import re import re
import sys
from enum import Enum from enum import Enum
from .typing import Final, Literal, PlatformName, assert_never from .typing import Final, Literal, PlatformName, assert_never
PRETTY_NAMES: Final = {"linux": "Linux", "macos": "macOS", "windows": "Windows"} PRETTY_NAMES: Final = {"linux": "Linux", "macos": "macOS", "windows": "Windows"}
ARCH_SYNONYMS: Final[list[dict[PlatformName, str | None]]] = [
{"linux": "x86_64", "macos": "x86_64", "windows": "AMD64"},
{"linux": "i686", "macos": None, "windows": "x86"},
{"linux": "aarch64", "macos": "arm64", "windows": "ARM64"},
]
@functools.total_ordering @functools.total_ordering
class Architecture(Enum): class Architecture(Enum):
@@ -56,14 +63,37 @@ class Architecture(Enum):
@staticmethod @staticmethod
def auto_archs(platform: PlatformName) -> set[Architecture]: def auto_archs(platform: PlatformName) -> set[Architecture]:
native_architecture = Architecture(platform_module.machine()) native_machine = platform_module.machine()
# Cross-platform support. Used for --print-build-identifiers or docker builds.
host_platform: PlatformName = (
"windows"
if sys.platform.startswith("win")
else ("macos" if sys.platform.startswith("darwin") else "linux")
)
native_architecture = Architecture(native_machine)
# we might need to rename the native arch to the machine we're running
# on, as the same arch can have different names on different platforms
if host_platform != platform:
for arch_synonym in ARCH_SYNONYMS:
if native_machine == arch_synonym.get(host_platform):
synonym = arch_synonym[platform]
if synonym is None:
# can't build anything on this platform
return set()
native_architecture = Architecture(synonym)
result = {native_architecture} result = {native_architecture}
if platform == "linux" and native_architecture == Architecture.x86_64: if platform == "linux" and Architecture.x86_64 in result:
# x86_64 machines can run i686 containers # x86_64 machines can run i686 containers
result.add(Architecture.i686) result.add(Architecture.i686)
if platform == "windows" and native_architecture == Architecture.AMD64: if platform == "windows" and Architecture.AMD64 in result:
result.add(Architecture.x86) result.add(Architecture.x86)
return result return result
+10 -8
View File
@@ -32,7 +32,8 @@ def evaluate(
command_node = bashlex.parsesingle(value) command_node = bashlex.parsesingle(value)
if len(command_node.parts) != 1: if len(command_node.parts) != 1:
raise ValueError(f'"{value}" has too many parts') msg = f"{value!r} has too many parts"
raise ValueError(msg)
value_word_node = command_node.parts[0] value_word_node = command_node.parts[0]
@@ -54,7 +55,8 @@ def evaluate_node(node: bashlex.ast.node, context: NodeExecutionContext) -> str:
elif node.kind == "parameter": elif node.kind == "parameter":
return evaluate_parameter_node(node, context=context) return evaluate_parameter_node(node, context=context)
else: else:
raise ValueError(f'Unsupported bash construct: "{node.kind}"') msg = f"Unsupported bash construct: {node.kind!r}"
raise ValueError(msg)
def evaluate_word_node(node: bashlex.ast.node, context: NodeExecutionContext) -> str: def evaluate_word_node(node: bashlex.ast.node, context: NodeExecutionContext) -> str:
@@ -65,10 +67,8 @@ def evaluate_word_node(node: bashlex.ast.node, context: NodeExecutionContext) ->
part_value = evaluate_node(part, context=context) part_value = evaluate_node(part, context=context)
if part_string not in value: if part_string not in value:
raise RuntimeError( msg = f"bash parse failed. part {part_string!r} not found in {value!r}. Word was {node.word!r}. Full input was {context.input!r}"
f'bash parse failed. part "{part_string}" not found in "{value}". ' raise RuntimeError(msg)
f'Word was "{node.word}". Full input was "{context.input}"'
)
value = value.replace(part_string, part_value, 1) value = value.replace(part_string, part_value, 1)
@@ -95,9 +95,11 @@ def evaluate_nodes_as_compound_command(
result += evaluate_command_node(node, context=context) result += evaluate_command_node(node, context=context)
elif node.kind == "operator": elif node.kind == "operator":
if node.op != ";": if node.op != ";":
raise ValueError(f'Unsupported bash operator: "{node.op}"') msg = f"Unsupported bash operator: {node.op!r}"
raise ValueError(msg)
else: else:
raise ValueError(f'Unsupported bash node in compound command: "{node.kind}"') msg = f"Unsupported bash node in compound command: {node.kind!r}"
raise ValueError(msg)
return result return result
+4 -7
View File
@@ -21,10 +21,8 @@ class cached_property(Generic[_T]):
if self.attrname is None: if self.attrname is None:
self.attrname = name self.attrname = name
elif name != self.attrname: elif name != self.attrname:
raise TypeError( msg = f"Cannot assign the same cached_property to two different names ({self.attrname!r} and {name!r})."
"Cannot assign the same cached_property to two different names " raise TypeError(msg)
f"({self.attrname!r} and {name!r})."
)
@overload @overload
def __get__(self, instance: None, owner: type[Any] | None = ...) -> cached_property[_T]: def __get__(self, instance: None, owner: type[Any] | None = ...) -> cached_property[_T]:
@@ -38,9 +36,8 @@ class cached_property(Generic[_T]):
if instance is None: if instance is None:
return self return self
if self.attrname is None: if self.attrname is None:
raise TypeError( msg = "Cannot use cached_property instance without calling __set_name__ on it."
"Cannot use cached_property instance without calling __set_name__ on it." raise TypeError(msg)
)
try: try:
cache = instance.__dict__ cache = instance.__dict__
except AttributeError: # not all objects have __dict__ (e.g. class defines slots) except AttributeError: # not all objects have __dict__ (e.g. class defines slots)
+2 -1
View File
@@ -367,7 +367,8 @@ def build(options: Options, tmp_path: Path) -> None: # pylint: disable=unused-a
cwd = Path.cwd() cwd = Path.cwd()
abs_package_dir = options.globals.package_dir.resolve() abs_package_dir = options.globals.package_dir.resolve()
if cwd != abs_package_dir and cwd not in abs_package_dir.parents: if cwd != abs_package_dir and cwd not in abs_package_dir.parents:
raise Exception("package_dir must be inside the working directory") msg = "package_dir must be inside the working directory"
raise Exception(msg)
container_project_path = PurePosixPath("/project") container_project_path = PurePosixPath("/project")
container_package_dir = container_project_path / abs_package_dir.relative_to(cwd) container_package_dir = container_project_path / abs_package_dir.relative_to(cwd)
+4 -2
View File
@@ -197,14 +197,16 @@ def build_description_from_identifier(identifier: str) -> str:
elif python_interpreter == "pp": elif python_interpreter == "pp":
build_description += "PyPy" build_description += "PyPy"
else: else:
raise Exception("unknown python") msg = f"unknown python {python_interpreter!r}"
raise Exception(msg)
build_description += f" {python_version[0]}.{python_version[1:]} " build_description += f" {python_version[0]}.{python_version[1:]} "
try: try:
build_description += PLATFORM_IDENTIFIER_DESCRIPTIONS[platform_identifier] build_description += PLATFORM_IDENTIFIER_DESCRIPTIONS[platform_identifier]
except KeyError as e: except KeyError as e:
raise Exception("unknown platform") from e msg = f"unknown platform {platform_identifier!r}"
raise Exception(msg) from e
return build_description return build_description
+4 -2
View File
@@ -146,7 +146,8 @@ def setup_python(
elif implementation_id.startswith("pp"): elif implementation_id.startswith("pp"):
base_python = install_pypy(tmp, python_configuration.url) base_python = install_pypy(tmp, python_configuration.url)
else: else:
raise ValueError("Unknown Python implementation") msg = "Unknown Python implementation"
raise ValueError(msg)
assert base_python.exists() assert base_python.exists()
log.step("Setting up build environment...") log.step("Setting up build environment...")
@@ -466,7 +467,8 @@ def build(options: Options, tmp_path: Path) -> None:
) )
) )
else: else:
raise RuntimeError("unreachable") msg = "unreachable"
raise RuntimeError(msg)
# skip this test # skip this test
continue continue
+2 -1
View File
@@ -58,7 +58,8 @@ class OCIContainer:
engine: ContainerEngine = "docker", engine: ContainerEngine = "docker",
): ):
if not image: if not image:
raise ValueError("Must have a non-empty image to run.") msg = "Must have a non-empty image to run."
raise ValueError(msg)
self.image = image self.image = image
self.simulate_32_bit = simulate_32_bit self.simulate_32_bit = simulate_32_bit
+10 -5
View File
@@ -138,7 +138,8 @@ def _dig_first(*pairs: tuple[Mapping[str, Setting], str], ignore_empty: bool = F
_dig_first((dict1, "key1"), (dict2, "key2"), ...) _dig_first((dict1, "key1"), (dict2, "key2"), ...)
""" """
if not pairs: if not pairs:
raise ValueError("pairs cannot be empty") msg = "pairs cannot be empty"
raise ValueError(msg)
for dict_like, key in pairs: for dict_like, key in pairs:
if key in dict_like: if key in dict_like:
@@ -208,13 +209,15 @@ class OptionsReader:
if config_overrides is not None: if config_overrides is not None:
if not isinstance(config_overrides, list): if not isinstance(config_overrides, list):
raise ConfigOptionError("'tool.cibuildwheel.overrides' must be a list") msg = "'tool.cibuildwheel.overrides' must be a list"
raise ConfigOptionError(msg)
for config_override in config_overrides: for config_override in config_overrides:
select = config_override.pop("select", None) select = config_override.pop("select", None)
if not select: if not select:
raise ConfigOptionError("'select' must be set in an override") msg = "'select' must be set in an override"
raise ConfigOptionError(msg)
if isinstance(select, list): if isinstance(select, list):
select = " ".join(select) select = " ".join(select)
@@ -328,14 +331,16 @@ class OptionsReader:
if isinstance(result, dict): if isinstance(result, dict):
if table is None: if table is None:
raise ConfigOptionError(f"{name!r} does not accept a table") msg = f"{name!r} does not accept a table"
raise ConfigOptionError(msg)
return table["sep"].join( return table["sep"].join(
item for k, v in result.items() for item in _inner_fmt(k, v, table) item for k, v in result.items() for item in _inner_fmt(k, v, table)
) )
if isinstance(result, list): if isinstance(result, list):
if sep is None: if sep is None:
raise ConfigOptionError(f"{name!r} does not accept a list") msg = f"{name!r} does not accept a list"
raise ConfigOptionError(msg)
return sep.join(result) return sep.join(result)
if isinstance(result, int): if isinstance(result, int):
+29 -29
View File
@@ -1,49 +1,49 @@
[x86_64] [x86_64]
manylinux1 = quay.io/pypa/manylinux1_x86_64:2022-09-07-2e53e4b manylinux1 = quay.io/pypa/manylinux1_x86_64:2022-09-18-e2e56b7
manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-08-05-4535177 manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-08-05-4535177
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2022-09-18-2b8b451
musllinux_1_1 = quay.io/pypa/musllinux_1_1_x86_64:2022-09-12-1a61614 musllinux_1_1 = quay.io/pypa/musllinux_1_1_x86_64:2022-09-18-2b8b451
[i686] [i686]
manylinux1 = quay.io/pypa/manylinux1_i686:2022-09-07-2e53e4b manylinux1 = quay.io/pypa/manylinux1_i686:2022-09-18-e2e56b7
manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-08-05-4535177 manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-08-05-4535177
manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-09-18-2b8b451
musllinux_1_1 = quay.io/pypa/musllinux_1_1_i686:2022-09-12-1a61614 musllinux_1_1 = quay.io/pypa/musllinux_1_1_i686:2022-09-18-2b8b451
[pypy_x86_64] [pypy_x86_64]
manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-08-05-4535177 manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-08-05-4535177
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_x86_64:2022-09-18-2b8b451
[pypy_i686] [pypy_i686]
manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-08-05-4535177 manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-08-05-4535177
manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-09-18-2b8b451
[aarch64] [aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2022-09-18-2b8b451
musllinux_1_1 = quay.io/pypa/musllinux_1_1_aarch64:2022-09-12-1a61614 musllinux_1_1 = quay.io/pypa/musllinux_1_1_aarch64:2022-09-18-2b8b451
[ppc64le] [ppc64le]
manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_ppc64le:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_ppc64le:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_ppc64le:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_ppc64le:2022-09-18-2b8b451
musllinux_1_1 = quay.io/pypa/musllinux_1_1_ppc64le:2022-09-12-1a61614 musllinux_1_1 = quay.io/pypa/musllinux_1_1_ppc64le:2022-09-18-2b8b451
[s390x] [s390x]
manylinux2014 = quay.io/pypa/manylinux2014_s390x:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_s390x:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_s390x:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_s390x:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_s390x:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_s390x:2022-09-18-2b8b451
musllinux_1_1 = quay.io/pypa/musllinux_1_1_s390x:2022-09-12-1a61614 musllinux_1_1 = quay.io/pypa/musllinux_1_1_s390x:2022-09-18-2b8b451
[pypy_aarch64] [pypy_aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-09-12-1a61614 manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-09-18-2b8b451
manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-09-12-1a61614 manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-09-18-2b8b451
manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2022-09-12-1a61614 manylinux_2_28 = quay.io/pypa/manylinux_2_28_aarch64:2022-09-18-2b8b451
+2 -1
View File
@@ -137,7 +137,8 @@ def setup_python(
assert python_configuration.url is not None assert python_configuration.url is not None
base_python = install_pypy(tmp, python_configuration.arch, python_configuration.url) base_python = install_pypy(tmp, python_configuration.arch, python_configuration.url)
else: else:
raise ValueError("Unknown Python implementation") msg = "Unknown Python implementation"
raise ValueError(msg)
assert base_python.exists() assert base_python.exists()
log.step("Setting up build environment...") log.step("Setting up build environment...")
+8
View File
@@ -4,6 +4,14 @@ title: Changelog
# Changelog # Changelog
### v2.10.2
_25 September 2022_
- 🐛 Fix a bug that caused `win32` identifiers to fail when used with `--only`. (#1282)
- 🐛 Fix computation of `auto`/`auto64`/`auto32` archs when targeting a different platform to the one that you're running cibuildwheel on. (#1266)
- 📚 Fix an mistake in the 'how it works' diagram. (#1274)
### v2.10.1 ### v2.10.1
_18 September 2022_ _18 September 2022_
Binary file not shown.

Before

Width:  |  Height:  |  Size: 76 KiB

After

Width:  |  Height:  |  Size: 67 KiB

+3 -3
View File
@@ -29,7 +29,7 @@
</div> </div>
<div class="grid-column-label" <div class="grid-column-label"
style="grid-row: 2 / span 1; style="grid-row: 2 / span 1;
grid-column: 8 / -3; grid-column: 9 / -3;
margin-bottom: 0.5em;"> margin-bottom: 0.5em;">
<div class="label">If tests are configured</div> <div class="label">If tests are configured</div>
</div> </div>
@@ -382,7 +382,7 @@
} }
.grid-column-label .label { .grid-column-label .label {
background: #fcfcfc; background: #fcfcfc;
padding: 0 2em; padding: 0 1em;
position: relative; position: relative;
} }
.grid-row-label { .grid-row-label {
@@ -420,7 +420,7 @@
grid-column: 3 / -2; grid-column: 3 / -2;
} }
.grid-outline.testVenv { .grid-outline.testVenv {
grid-column: 8 / span 4; grid-column: 9 / span 3;
} }
.grid-outline .outline { .grid-outline .outline {
position: absolute; position: absolute;
+2 -2
View File
@@ -142,7 +142,7 @@ There are two suggested methods for keeping cibuildwheel up to date that instead
If you use GitHub Actions for builds, you can use cibuildwheel as an action: If you use GitHub Actions for builds, you can use cibuildwheel as an action:
```yaml ```yaml
uses: pypa/cibuildwheel@v2.10.1 uses: pypa/cibuildwheel@v2.10.2
``` ```
This is a composite step that just runs cibuildwheel using pipx. You can set command-line options as `with:` parameters, and use `env:` as normal. This is a composite step that just runs cibuildwheel using pipx. You can set command-line options as `with:` parameters, and use `env:` as normal.
@@ -164,7 +164,7 @@ The second option, and the only one that supports other CI systems, is using a `
```bash ```bash
# requirements-cibw.txt # requirements-cibw.txt
cibuildwheel==2.10.1 cibuildwheel==2.10.2
``` ```
Then your install step would have `python -m pip install -r requirements-cibw.txt` in it. Your `.github/dependabot.yml` file could look like this: Then your install step would have `python -m pip install -r requirements-cibw.txt` in it. Your `.github/dependabot.yml` file could look like this:
+2 -2
View File
@@ -184,7 +184,7 @@ To build Linux, Mac, and Windows wheels using GitHub Actions, create a `.github/
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- name: Build wheels - name: Build wheels
run: pipx run cibuildwheel==2.10.1 run: pipx run cibuildwheel==2.10.2
- uses: actions/upload-artifact@v3 - uses: actions/upload-artifact@v3
with: with:
@@ -219,7 +219,7 @@ To build Linux, Mac, and Windows wheels using GitHub Actions, create a `.github/
- uses: actions/setup-python@v3 - uses: actions/setup-python@v3
- name: Install cibuildwheel - name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.10.1 run: python -m pip install cibuildwheel==2.10.2
- name: Build wheels - name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse run: python -m cibuildwheel --output-dir wheelhouse
+109 -109
View File
@@ -40,8 +40,8 @@ title: Working examples
| [pyzmq][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Python bindings for zeromq, the networking library. Uses Cython and CFFI. | | [pyzmq][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Python bindings for zeromq, the networking library. Uses Cython and CFFI. |
| [aiortc][] | ![github icon][] | ![apple icon][] ![linux icon][] | WebRTC and ORTC implementation for Python using asyncio. | | [aiortc][] | ![github icon][] | ![apple icon][] ![linux icon][] | WebRTC and ORTC implementation for Python using asyncio. |
| [Implicit][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes GPU support for linux wheels | | [Implicit][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes GPU support for linux wheels |
| [vispy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Main repository for Vispy |
| [Confluent client for Kafka][] | ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | setup in `tools/wheels/build-wheels.bat` | | [Confluent client for Kafka][] | ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | setup in `tools/wheels/build-wheels.bat` |
| [vispy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Main repository for Vispy |
| [tinyobjloader][] | ![azurepipelines icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Tiny but powerful single file wavefront obj loader | | [tinyobjloader][] | ![azurepipelines icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Tiny but powerful single file wavefront obj loader |
| [Dependency Injector][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Dependency injection framework for Python, uses Windows TravisCI | | [Dependency Injector][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Dependency injection framework for Python, uses Windows TravisCI |
| [coverage.py][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The coverage tool for Python | | [coverage.py][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The coverage tool for Python |
@@ -53,13 +53,13 @@ title: Working examples
| [PyAV][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Pythonic bindings for FFmpeg's libraries. | | [PyAV][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Pythonic bindings for FFmpeg's libraries. |
| [SimpleJSON][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | simplejson is a simple, fast, extensible JSON encoder/decoder for Python | | [SimpleJSON][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | simplejson is a simple, fast, extensible JSON encoder/decoder for Python |
| [pikepdf][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python library for reading and writing PDF, powered by qpdf | | [pikepdf][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python library for reading and writing PDF, powered by qpdf |
| [OpenColorIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A color management framework for visual effects and animation. |
| [Line Profiler][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Line-by-line profiling for Python | | [Line Profiler][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Line-by-line profiling for Python |
| [OpenColorIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A color management framework for visual effects and animation. |
| [PyTables][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python package to manage extremely large amounts of data | | [PyTables][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python package to manage extremely large amounts of data |
| [OpenTimelineIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Open Source API and interchange format for editorial timeline information. | | [OpenTimelineIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Open Source API and interchange format for editorial timeline information. |
| [aioquic][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | QUIC and HTTP/3 implementation in Python | | [aioquic][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | QUIC and HTTP/3 implementation in Python |
| [ruptures][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Extensive Cython + NumPy [pyproject.toml](https://github.com/deepcharles/ruptures/blob/master/pyproject.toml) example. | | [ruptures][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Extensive Cython + NumPy [pyproject.toml](https://github.com/deepcharles/ruptures/blob/master/pyproject.toml) example. |
| [envd][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | 🏕️ Development environment for AI/ML | | [envd][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | 🏕️ Development environment for AI/ML, based on buildkit |
| [Psycopg 3][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A modern implementation of a PostgreSQL adapter for Python | | [Psycopg 3][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A modern implementation of a PostgreSQL adapter for Python |
| [DeepForest][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | An Efficient, Scalable and Optimized Python Framework for Deep Forest (2021.2.1) | | [DeepForest][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | An Efficient, Scalable and Optimized Python Framework for Deep Forest (2021.2.1) |
| [google neuroglancer][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | WebGL-based viewer for volumetric data | | [google neuroglancer][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | WebGL-based viewer for volumetric data |
@@ -88,8 +88,8 @@ title: Working examples
| [bx-python][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | A library that includes Cython extensions. | | [bx-python][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | A library that includes Cython extensions. |
| [boost-histogram][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Supports full range of wheels, including PyPy and alternate archs. | | [boost-histogram][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Supports full range of wheels, including PyPy and alternate archs. |
| [TgCrypto][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes a Windows Travis build. | | [TgCrypto][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes a Windows Travis build. |
| [iDynTree][] | ![github icon][] | ![linux icon][] | Uses manylinux_2_24 |
| [mosec][] | ![github icon][] | ![linux icon][] ![apple icon][] | A high-performance serving framework for ML models, offers dynamic batching and multi-stage pipeline to fully exploit your compute machine | | [mosec][] | ![github icon][] | ![linux icon][] ![apple icon][] | A high-performance serving framework for ML models, offers dynamic batching and multi-stage pipeline to fully exploit your compute machine |
| [iDynTree][] | ![github icon][] | ![linux icon][] | Uses manylinux_2_24 |
| [Python-WebRTC][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | a Python extension that provides bindings to WebRTC M92 | | [Python-WebRTC][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | a Python extension that provides bindings to WebRTC M92 |
| [pybase64][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast Base64 encoding/decoding in Python | | [pybase64][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast Base64 encoding/decoding in Python |
| [Arbor][] | ![github icon][] | ![apple icon][] ![linux icon][] | Arbor is a multi-compartment neuron simulation library; compatible with next-generation accelerators; best-practices applied to research software; focused on community-driven development. Includes a [small script](https://github.com/arbor-sim/arbor/blob/master/scripts/patchwheel.py) patching `rpath` in bundled libraries. | | [Arbor][] | ![github icon][] | ![apple icon][] ![linux icon][] | Arbor is a multi-compartment neuron simulation library; compatible with next-generation accelerators; best-practices applied to research software; focused on community-driven development. Includes a [small script](https://github.com/arbor-sim/arbor/blob/master/scripts/patchwheel.py) patching `rpath` in bundled libraries. |
@@ -144,8 +144,8 @@ title: Working examples
[pyzmq]: https://github.com/zeromq/pyzmq [pyzmq]: https://github.com/zeromq/pyzmq
[aiortc]: https://github.com/aiortc/aiortc [aiortc]: https://github.com/aiortc/aiortc
[Implicit]: https://github.com/benfred/implicit [Implicit]: https://github.com/benfred/implicit
[vispy]: https://github.com/vispy/vispy
[Confluent client for Kafka]: https://github.com/confluentinc/confluent-kafka-python [Confluent client for Kafka]: https://github.com/confluentinc/confluent-kafka-python
[vispy]: https://github.com/vispy/vispy
[tinyobjloader]: https://github.com/tinyobjloader/tinyobjloader [tinyobjloader]: https://github.com/tinyobjloader/tinyobjloader
[Dependency Injector]: https://github.com/ets-labs/python-dependency-injector [Dependency Injector]: https://github.com/ets-labs/python-dependency-injector
[coverage.py]: https://github.com/nedbat/coveragepy [coverage.py]: https://github.com/nedbat/coveragepy
@@ -157,8 +157,8 @@ title: Working examples
[PyAV]: https://github.com/PyAV-Org/PyAV [PyAV]: https://github.com/PyAV-Org/PyAV
[SimpleJSON]: https://github.com/simplejson/simplejson [SimpleJSON]: https://github.com/simplejson/simplejson
[pikepdf]: https://github.com/pikepdf/pikepdf [pikepdf]: https://github.com/pikepdf/pikepdf
[OpenColorIO]: https://github.com/AcademySoftwareFoundation/OpenColorIO
[Line Profiler]: https://github.com/pyutils/line_profiler [Line Profiler]: https://github.com/pyutils/line_profiler
[OpenColorIO]: https://github.com/AcademySoftwareFoundation/OpenColorIO
[PyTables]: https://github.com/PyTables/PyTables [PyTables]: https://github.com/PyTables/PyTables
[OpenTimelineIO]: https://github.com/PixarAnimationStudios/OpenTimelineIO [OpenTimelineIO]: https://github.com/PixarAnimationStudios/OpenTimelineIO
[aioquic]: https://github.com/aiortc/aioquic [aioquic]: https://github.com/aiortc/aioquic
@@ -192,8 +192,8 @@ title: Working examples
[bx-python]: https://github.com/bxlab/bx-python [bx-python]: https://github.com/bxlab/bx-python
[boost-histogram]: https://github.com/scikit-hep/boost-histogram [boost-histogram]: https://github.com/scikit-hep/boost-histogram
[TgCrypto]: https://github.com/pyrogram/tgcrypto [TgCrypto]: https://github.com/pyrogram/tgcrypto
[iDynTree]: https://github.com/robotology/idyntree
[mosec]: https://github.com/mosecorg/mosec [mosec]: https://github.com/mosecorg/mosec
[iDynTree]: https://github.com/robotology/idyntree
[Python-WebRTC]: https://github.com/MarshalX/python-webrtc [Python-WebRTC]: https://github.com/MarshalX/python-webrtc
[pybase64]: https://github.com/mayeut/pybase64 [pybase64]: https://github.com/mayeut/pybase64
[Arbor]: https://github.com/arbor-sim/arbor [Arbor]: https://github.com/arbor-sim/arbor
@@ -227,109 +227,109 @@ title: Working examples
[apple icon]: data/readme_icons/apple.svg [apple icon]: data/readme_icons/apple.svg
[linux icon]: data/readme_icons/linux.svg [linux icon]: data/readme_icons/linux.svg
<!-- scikit-learn: 51343, last pushed 0 days ago --> <!-- scikit-learn: 51403, last pushed 0 days ago -->
<!-- NumPy: 21419, last pushed 0 days ago --> <!-- NumPy: 21474, last pushed 0 days ago -->
<!-- Tornado: 20737, last pushed 5 days ago --> <!-- Tornado: 20743, last pushed 12 days ago -->
<!-- pytorch-fairseq: 19138, last pushed 2 days ago --> <!-- pytorch-fairseq: 19191, last pushed 2 days ago -->
<!-- Matplotlib: 16103, last pushed 0 days ago --> <!-- Matplotlib: 16136, last pushed 0 days ago -->
<!-- NCNN: 15461, last pushed 1 days ago --> <!-- NCNN: 15506, last pushed 0 days ago -->
<!-- Kivy: 15002, last pushed 0 days ago --> <!-- Kivy: 15023, last pushed 6 days ago -->
<!-- Prophet: 14896, last pushed 3 days ago --> <!-- Prophet: 14915, last pushed 1 days ago -->
<!-- MyPy: 13758, last pushed 0 days ago --> <!-- MyPy: 13792, last pushed 0 days ago -->
<!-- pydantic: 11038, last pushed 3 days ago --> <!-- pydantic: 11091, last pushed 2 days ago -->
<!-- MemRay: 9212, last pushed 2 days ago --> <!-- MemRay: 9238, last pushed 0 days ago -->
<!-- uvloop: 8849, last pushed 0 days ago --> <!-- uvloop: 8881, last pushed 2 days ago -->
<!-- psutil: 8679, last pushed 3 days ago --> <!-- psutil: 8696, last pushed 0 days ago -->
<!-- vaex: 7291, last pushed 4 days ago --> <!-- vaex: 7296, last pushed 2 days ago -->
<!-- Google Benchmark: 6820, last pushed 0 days ago --> <!-- Google Benchmark: 6836, last pushed 4 days ago -->
<!-- duckdb: 6335, last pushed 0 days ago --> <!-- duckdb: 6390, last pushed 0 days ago -->
<!-- Apache Beam: 5843, last pushed 0 days ago --> <!-- Apache Beam: 5862, last pushed 0 days ago -->
<!-- asyncpg: 5624, last pushed 3 days ago --> <!-- asyncpg: 5635, last pushed 1 days ago -->
<!-- PyGame: 5195, last pushed 0 days ago --> <!-- PyGame: 5210, last pushed 0 days ago -->
<!-- cmake: 5050, last pushed 0 days ago --> <!-- cmake: 5079, last pushed 0 days ago -->
<!-- scikit-image: 5038, last pushed 0 days ago --> <!-- scikit-image: 5042, last pushed 0 days ago -->
<!-- twisted-iocpsupport: 4742, last pushed 0 days ago --> <!-- twisted-iocpsupport: 4749, last pushed 0 days ago -->
<!-- PyOxidizer: 4275, last pushed 5 days ago --> <!-- PyOxidizer: 4292, last pushed 0 days ago -->
<!-- websockets: 4156, last pushed 0 days ago --> <!-- websockets: 4163, last pushed 2 days ago -->
<!-- cvxpy: 4073, last pushed 0 days ago --> <!-- cvxpy: 4082, last pushed 0 days ago -->
<!-- Triton: 3980, last pushed 0 days ago --> <!-- Triton: 4009, last pushed 0 days ago -->
<!-- UltraJSON: 3830, last pushed 34 days ago --> <!-- UltraJSON: 3840, last pushed 3 days ago -->
<!-- River: 3610, last pushed 0 days ago --> <!-- River: 3622, last pushed 3 days ago -->
<!-- OpenSpiel: 3315, last pushed 1 days ago --> <!-- OpenSpiel: 3318, last pushed 1 days ago -->
<!-- pyzmq: 3155, last pushed 0 days ago --> <!-- pyzmq: 3156, last pushed 2 days ago -->
<!-- aiortc: 3059, last pushed 5 days ago --> <!-- aiortc: 3072, last pushed 12 days ago -->
<!-- Implicit: 2939, last pushed 11 days ago --> <!-- Implicit: 2946, last pushed 18 days ago -->
<!-- vispy: 2927, last pushed 1 days ago --> <!-- Confluent client for Kafka: 2932, last pushed 1 days ago -->
<!-- Confluent client for Kafka: 2922, last pushed 0 days ago --> <!-- vispy: 2931, last pushed 0 days ago -->
<!-- tinyobjloader: 2637, last pushed 69 days ago --> <!-- tinyobjloader: 2643, last pushed 75 days ago -->
<!-- Dependency Injector: 2346, last pushed 3 days ago --> <!-- Dependency Injector: 2361, last pushed 10 days ago -->
<!-- coverage.py: 2182, last pushed 4 days ago --> <!-- coverage.py: 2196, last pushed 1 days ago -->
<!-- PyCryptodome: 2119, last pushed 10 days ago --> <!-- PyCryptodome: 2125, last pushed 16 days ago -->
<!-- PyYAML: 1930, last pushed 15 days ago --> <!-- PyYAML: 1932, last pushed 5 days ago -->
<!-- numexpr: 1810, last pushed 6 days ago --> <!-- numexpr: 1813, last pushed 13 days ago -->
<!-- h5py: 1777, last pushed 5 days ago --> <!-- h5py: 1778, last pushed 1 days ago -->
<!-- Wrapt: 1741, last pushed 18 days ago --> <!-- Wrapt: 1743, last pushed 25 days ago -->
<!-- PyAV: 1651, last pushed 13 days ago --> <!-- PyAV: 1659, last pushed 5 days ago -->
<!-- SimpleJSON: 1517, last pushed 73 days ago --> <!-- SimpleJSON: 1519, last pushed 79 days ago -->
<!-- pikepdf: 1488, last pushed 0 days ago --> <!-- pikepdf: 1491, last pushed 0 days ago -->
<!-- OpenColorIO: 1363, last pushed 1 days ago --> <!-- Line Profiler: 1372, last pushed 2 days ago -->
<!-- Line Profiler: 1362, last pushed 0 days ago --> <!-- OpenColorIO: 1364, last pushed 8 days ago -->
<!-- PyTables: 1146, last pushed 5 days ago --> <!-- PyTables: 1148, last pushed 3 days ago -->
<!-- OpenTimelineIO: 1092, last pushed 0 days ago --> <!-- OpenTimelineIO: 1096, last pushed 0 days ago -->
<!-- aioquic: 1051, last pushed 3 days ago --> <!-- aioquic: 1055, last pushed 1 days ago -->
<!-- ruptures: 1040, last pushed 18 days ago --> <!-- ruptures: 1043, last pushed 24 days ago -->
<!-- envd: 877, last pushed 0 days ago --> <!-- envd: 988, last pushed 0 days ago -->
<!-- Psycopg 3: 781, last pushed 3 days ago --> <!-- Psycopg 3: 784, last pushed 0 days ago -->
<!-- DeepForest: 775, last pushed 121 days ago --> <!-- DeepForest: 777, last pushed 0 days ago -->
<!-- google neuroglancer: 752, last pushed 3 days ago --> <!-- google neuroglancer: 753, last pushed 10 days ago -->
<!-- Parselmouth: 687, last pushed 64 days ago --> <!-- Parselmouth: 695, last pushed 70 days ago -->
<!-- AutoPy: 674, last pushed 261 days ago --> <!-- AutoPy: 674, last pushed 267 days ago -->
<!-- H3-py: 560, last pushed 14 days ago --> <!-- H3-py: 560, last pushed 21 days ago -->
<!-- Rtree: 502, last pushed 146 days ago --> <!-- Rtree: 502, last pushed 152 days ago -->
<!-- markupsafe: 494, last pushed 6 days ago --> <!-- markupsafe: 494, last pushed 13 days ago -->
<!-- python-rapidjson: 457, last pushed 54 days ago --> <!-- python-rapidjson: 459, last pushed 60 days ago -->
<!-- python-snappy: 443, last pushed 180 days ago --> <!-- python-snappy: 443, last pushed 186 days ago -->
<!-- pybind11 cmake_example: 438, last pushed 31 days ago --> <!-- pybind11 cmake_example: 441, last pushed 2 days ago -->
<!-- KDEpy: 402, last pushed 214 days ago --> <!-- KDEpy: 404, last pushed 220 days ago -->
<!-- tgcalls: 388, last pushed 72 days ago --> <!-- tgcalls: 390, last pushed 79 days ago -->
<!-- pybind11 python_example: 360, last pushed 31 days ago --> <!-- pybind11 python_example: 363, last pushed 0 days ago -->
<!-- dd-trace-py: 355, last pushed 0 days ago --> <!-- dd-trace-py: 357, last pushed 0 days ago -->
<!-- CTranslate2: 333, last pushed 0 days ago --> <!-- CTranslate2: 334, last pushed 2 days ago -->
<!-- time-machine: 325, last pushed 0 days ago --> <!-- time-machine: 330, last pushed 6 days ago -->
<!-- sourmash: 320, last pushed 4 days ago --> <!-- sourmash: 321, last pushed 0 days ago -->
<!-- cyvcf2: 304, last pushed 28 days ago --> <!-- cyvcf2: 305, last pushed 34 days ago -->
<!-- matrixprofile: 283, last pushed 70 days ago --> <!-- matrixprofile: 285, last pushed 76 days ago -->
<!-- abess: 280, last pushed 1 days ago --> <!-- abess: 282, last pushed 7 days ago -->
<!-- jq.py: 228, last pushed 0 days ago --> <!-- jq.py: 229, last pushed 6 days ago -->
<!-- iminuit: 211, last pushed 17 days ago --> <!-- iminuit: 212, last pushed 23 days ago -->
<!-- Tokenizer: 187, last pushed 0 days ago --> <!-- Tokenizer: 187, last pushed 5 days ago -->
<!-- PyGLM: 150, last pushed 167 days ago --> <!-- PyGLM: 151, last pushed 174 days ago -->
<!-- bx-python: 116, last pushed 15 days ago --> <!-- bx-python: 118, last pushed 21 days ago -->
<!-- boost-histogram: 116, last pushed 6 days ago --> <!-- boost-histogram: 116, last pushed 1 days ago -->
<!-- TgCrypto: 110, last pushed 192 days ago --> <!-- TgCrypto: 110, last pushed 198 days ago -->
<!-- iDynTree: 108, last pushed 0 days ago --> <!-- mosec: 109, last pushed 2 days ago -->
<!-- mosec: 105, last pushed 2 days ago --> <!-- iDynTree: 108, last pushed 3 days ago -->
<!-- Python-WebRTC: 93, last pushed 185 days ago --> <!-- Python-WebRTC: 94, last pushed 192 days ago -->
<!-- pybase64: 88, last pushed 6 days ago --> <!-- pybase64: 88, last pushed 5 days ago -->
<!-- Arbor: 78, last pushed 0 days ago --> <!-- Arbor: 80, last pushed 1 days ago -->
<!-- fathon: 68, last pushed 102 days ago --> <!-- fathon: 68, last pushed 108 days ago -->
<!-- etebase-py: 58, last pushed 67 days ago --> <!-- etebase-py: 58, last pushed 74 days ago -->
<!-- polaroid: 53, last pushed 124 days ago --> <!-- polaroid: 54, last pushed 130 days ago -->
<!-- cf-units: 49, last pushed 0 days ago --> <!-- cf-units: 49, last pushed 0 days ago -->
<!-- Imagecodecs (fork): 48, last pushed 34 days ago --> <!-- Imagecodecs (fork): 48, last pushed 41 days ago -->
<!-- pillow-heif: 47, last pushed 0 days ago --> <!-- pillow-heif: 48, last pushed 6 days ago -->
<!-- power-grid-model: 46, last pushed 0 days ago --> <!-- power-grid-model: 48, last pushed 2 days ago -->
<!-- clang-format: 43, last pushed 6 days ago --> <!-- clang-format: 43, last pushed 12 days ago -->
<!-- numpythia: 34, last pushed 11 days ago --> <!-- numpythia: 34, last pushed 18 days ago -->
<!-- pybind11 scikit_build_example: 33, last pushed 31 days ago --> <!-- pybind11 scikit_build_example: 33, last pushed 0 days ago -->
<!-- pyjet: 32, last pushed 11 days ago --> <!-- pyjet: 32, last pushed 18 days ago -->
<!-- ninja: 25, last pushed 6 days ago --> <!-- ninja: 25, last pushed 0 days ago -->
<!-- GSD: 19, last pushed 0 days ago --> <!-- GSD: 19, last pushed 6 days ago -->
<!-- pyinstrument_cext: 10, last pushed 339 days ago --> <!-- pyinstrument_cext: 10, last pushed 345 days ago -->
<!-- CorrectionLib: 10, last pushed 0 days ago --> <!-- CorrectionLib: 10, last pushed 4 days ago -->
<!-- xmlstarlet: 9, last pushed 28 days ago --> <!-- xmlstarlet: 9, last pushed 34 days ago -->
<!-- SiPM: 7, last pushed 103 days ago --> <!-- SiPM: 8, last pushed 109 days ago -->
<!-- ril: 5, last pushed 0 days ago --> <!-- ril: 5, last pushed 5 days ago -->
<!-- END bin/projects.py --> <!-- END bin/projects.py -->
+1 -1
View File
@@ -12,7 +12,7 @@ stack: python 3.7
init: init:
- cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH% - cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH%
install: python -m pip install cibuildwheel==2.10.1 install: python -m pip install cibuildwheel==2.10.2
build_script: python -m cibuildwheel --output-dir wheelhouse build_script: python -m cibuildwheel --output-dir wheelhouse
+3 -3
View File
@@ -6,7 +6,7 @@ jobs:
- bash: | - bash: |
set -o errexit set -o errexit
python3 -m pip install --upgrade pip python3 -m pip install --upgrade pip
pip3 install cibuildwheel==2.10.1 pip3 install cibuildwheel==2.10.2
displayName: Install dependencies displayName: Install dependencies
- bash: cibuildwheel --output-dir wheelhouse . - bash: cibuildwheel --output-dir wheelhouse .
displayName: Build wheels displayName: Build wheels
@@ -20,7 +20,7 @@ jobs:
- bash: | - bash: |
set -o errexit set -o errexit
python3 -m pip install --upgrade pip python3 -m pip install --upgrade pip
python3 -m pip install cibuildwheel==2.10.1 python3 -m pip install cibuildwheel==2.10.2
displayName: Install dependencies displayName: Install dependencies
- bash: cibuildwheel --output-dir wheelhouse . - bash: cibuildwheel --output-dir wheelhouse .
displayName: Build wheels displayName: Build wheels
@@ -34,7 +34,7 @@ jobs:
- bash: | - bash: |
set -o errexit set -o errexit
python -m pip install --upgrade pip python -m pip install --upgrade pip
pip install cibuildwheel==2.10.1 pip install cibuildwheel==2.10.2
displayName: Install dependencies displayName: Install dependencies
- bash: cibuildwheel --output-dir wheelhouse . - bash: cibuildwheel --output-dir wheelhouse .
displayName: Build wheels displayName: Build wheels
+2 -2
View File
@@ -11,7 +11,7 @@ jobs:
- run: - run:
name: Build the Linux wheels. name: Build the Linux wheels.
command: | command: |
pip3 install --user cibuildwheel==2.10.1 pip3 install --user cibuildwheel==2.10.2
cibuildwheel --output-dir wheelhouse cibuildwheel --output-dir wheelhouse
- store_artifacts: - store_artifacts:
path: wheelhouse/ path: wheelhouse/
@@ -25,7 +25,7 @@ jobs:
- run: - run:
name: Build the OS X wheels. name: Build the OS X wheels.
command: | command: |
pip3 install cibuildwheel==2.10.1 pip3 install cibuildwheel==2.10.2
cibuildwheel --output-dir wheelhouse cibuildwheel --output-dir wheelhouse
- store_artifacts: - store_artifacts:
path: wheelhouse/ path: wheelhouse/
+1 -1
View File
@@ -1,6 +1,6 @@
build_and_store_wheels: &BUILD_AND_STORE_WHEELS build_and_store_wheels: &BUILD_AND_STORE_WHEELS
install_cibuildwheel_script: install_cibuildwheel_script:
- python -m pip install cibuildwheel==2.10.1 - python -m pip install cibuildwheel==2.10.2
run_cibuildwheel_script: run_cibuildwheel_script:
- cibuildwheel - cibuildwheel
wheels_artifacts: wheels_artifacts:
+1 -1
View File
@@ -1,6 +1,6 @@
build_and_store_wheels: &BUILD_AND_STORE_WHEELS build_and_store_wheels: &BUILD_AND_STORE_WHEELS
install_cibuildwheel_script: install_cibuildwheel_script:
- python -m pip install cibuildwheel==2.10.1 - python -m pip install cibuildwheel==2.10.2
run_cibuildwheel_script: run_cibuildwheel_script:
- cibuildwheel - cibuildwheel
wheels_artifacts: wheels_artifacts:
+1 -1
View File
@@ -10,7 +10,7 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.10.1 uses: pypa/cibuildwheel@v2.10.2
env: env:
CIBW_ARCHS_MACOS: x86_64 arm64 CIBW_ARCHS_MACOS: x86_64 arm64
+1 -1
View File
@@ -22,7 +22,7 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.10.1 uses: pypa/cibuildwheel@v2.10.2
- uses: actions/upload-artifact@v3 - uses: actions/upload-artifact@v3
with: with:
+1 -1
View File
@@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.10.1 uses: pypa/cibuildwheel@v2.10.2
# env: # env:
# CIBW_SOME_OPTION: value # CIBW_SOME_OPTION: value
# ... # ...
+1 -1
View File
@@ -20,7 +20,7 @@ jobs:
platforms: all platforms: all
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.10.1 uses: pypa/cibuildwheel@v2.10.2
env: env:
# configure cibuildwheel to build native archs ('auto'), and some # configure cibuildwheel to build native archs ('auto'), and some
# emulated ones # emulated ones
+1 -1
View File
@@ -12,7 +12,7 @@ linux:
DOCKER_TLS_CERTDIR: "" DOCKER_TLS_CERTDIR: ""
script: script:
- curl -sSL https://get.docker.com/ | sh - curl -sSL https://get.docker.com/ | sh
- python -m pip install cibuildwheel==2.10.1 - python -m pip install cibuildwheel==2.10.2
- cibuildwheel --output-dir wheelhouse - cibuildwheel --output-dir wheelhouse
artifacts: artifacts:
paths: paths:
+1 -1
View File
@@ -19,7 +19,7 @@ jobs:
- ln -s /c/Python38/python.exe /c/Python38/python3.exe - ln -s /c/Python38/python.exe /c/Python38/python3.exe
install: install:
- python3 -m pip install cibuildwheel==2.10.1 - python3 -m pip install cibuildwheel==2.10.2
script: script:
# build the wheels, put them into './dist' # build the wheels, put them into './dist'
+1 -1
View File
@@ -25,7 +25,7 @@ jobs:
- ln -s /c/Python38/python.exe /c/Python38/python3.exe - ln -s /c/Python38/python.exe /c/Python38/python3.exe
install: install:
- python3 -m pip install cibuildwheel==2.10.1 - python3 -m pip install cibuildwheel==2.10.2
script: script:
# build the wheels, put them into './wheelhouse' # build the wheels, put them into './wheelhouse'
+2 -2
View File
@@ -54,7 +54,7 @@ jobs:
- stage: deploy - stage: deploy
name: Build and deploy Linux wheels name: Build and deploy Linux wheels
services: docker services: docker
install: python3 -m pip install cibuildwheel==2.10.1 twine install: python3 -m pip install cibuildwheel==2.10.2 twine
script: python3 -m cibuildwheel --output-dir wheelhouse script: python3 -m cibuildwheel --output-dir wheelhouse
after_success: python3 -m twine upload --skip-existing wheelhouse/*.whl after_success: python3 -m twine upload --skip-existing wheelhouse/*.whl
# Deploy on windows # Deploy on windows
@@ -62,7 +62,7 @@ jobs:
name: Build and deploy Windows wheels name: Build and deploy Windows wheels
os: windows os: windows
language: shell language: shell
install: python3 -m pip install cibuildwheel==2.10.1 twine install: python3 -m pip install cibuildwheel==2.10.2 twine
script: python3 -m cibuildwheel --output-dir wheelhouse script: python3 -m cibuildwheel --output-dir wheelhouse
after_success: python3 -m twine upload --skip-existing wheelhouse/*.whl after_success: python3 -m twine upload --skip-existing wheelhouse/*.whl
-1
View File
@@ -68,7 +68,6 @@ module = [
"bashlex", "bashlex",
"bashlex.*", "bashlex.*",
"importlib_resources", "importlib_resources",
"ghapi.*",
] ]
ignore_missing_imports = true ignore_missing_imports = true
+1 -1
View File
@@ -1,6 +1,6 @@
[metadata] [metadata]
name = cibuildwheel name = cibuildwheel
version = 2.10.1 version = 2.10.2
description = Build Python wheels on CI with minimal configuration. description = Build Python wheels on CI with minimal configuration.
long_description = file: README.md long_description = file: README.md
long_description_content_type = text/markdown long_description_content_type = text/markdown
-3
View File
@@ -20,7 +20,6 @@ extras = {
], ],
"bin": [ "bin": [
"click", "click",
"ghapi",
"pip-tools", "pip-tools",
"pygithub", "pygithub",
"pyyaml", "pyyaml",
@@ -46,6 +45,4 @@ extras["dev"] = [
*extras["bin"], *extras["bin"],
] ]
extras["all"] = sum(extras.values(), [])
setup(extras_require=extras) setup(extras_require=extras)
+2 -1
View File
@@ -108,7 +108,8 @@ def test_pinned_versions(tmp_path, python_version, build_frontend_env):
w for w in utils.expected_wheels("spam", "0.1.0") if "-cp39" in w or "-pp39" in w w for w in utils.expected_wheels("spam", "0.1.0") if "-cp39" in w or "-pp39" in w
] ]
else: else:
raise ValueError("unhandled python version") msg = "unhandled python version"
raise ValueError(msg)
assert set(actual_wheels) == set(expected_wheels) assert set(actual_wheels) == set(expected_wheels)
+4 -2
View File
@@ -23,7 +23,8 @@ elif sys.platform.startswith("darwin"):
elif sys.platform in ["win32", "cygwin"]: elif sys.platform in ["win32", "cygwin"]:
platform = "windows" platform = "windows"
else: else:
raise Exception("Unsupported platform") msg = f"Unsupported platform {sys.platform!r}"
raise Exception(msg)
def cibuildwheel_get_build_identifiers(project_path, env=None, *, prerelease_pythons=False): def cibuildwheel_get_build_identifiers(project_path, env=None, *, prerelease_pythons=False):
@@ -210,7 +211,8 @@ def expected_wheels(
) )
else: else:
raise Exception("unsupported platform") msg = f"Unsupported platform {platform!r}"
raise Exception(msg)
for platform_tag in platform_tags: for platform_tag in platform_tags:
wheels.append(f"{package_name}-{package_version}-{python_abi_tag}-{platform_tag}.whl") wheels.append(f"{package_name}-{package_version}-{python_abi_tag}-{platform_tag}.whl")
+82
View File
@@ -0,0 +1,82 @@
from __future__ import annotations
import platform as platform_module
import sys
import pytest
from cibuildwheel.architecture import Architecture
@pytest.fixture(
params=[
pytest.param(("linux", "linux", "x86_64", "64"), id="linux-64"),
pytest.param(("linux", "linux", "i686", "32"), id="linux-32"),
pytest.param(("linux", "linux", "aarch64", "arm"), id="linux-arm"),
pytest.param(("macos", "darwin", "x86_64", "64"), id="macos-64"),
pytest.param(("macos", "darwin", "arm64", "arm"), id="macos-arm"),
pytest.param(("windows", "win32", "x86", "32"), id="windows-32"),
pytest.param(("windows", "win32", "AMD64", "64"), id="windows-64"),
pytest.param(("windows", "win32", "ARM64", "arm"), id="windows-arm"),
]
)
def platform_machine(request, monkeypatch):
platform_name, platform_value, machine_value, machine_name = request.param
monkeypatch.setattr(sys, "platform", platform_value)
monkeypatch.setattr(platform_module, "machine", lambda: machine_value)
return platform_name, machine_name
def test_arch_auto(platform_machine):
platform_name, machine_name = platform_machine
arch_set = Architecture.auto_archs("linux")
expected = {
"32": {Architecture.i686},
"64": {Architecture.x86_64, Architecture.i686},
"arm": {Architecture.aarch64},
}
assert arch_set == expected[machine_name]
arch_set = Architecture.auto_archs("macos")
expected = {"32": set(), "64": {Architecture.x86_64}, "arm": {Architecture.arm64}}
assert arch_set == expected[machine_name]
arch_set = Architecture.auto_archs("windows")
expected = {
"32": {Architecture.x86},
"64": {Architecture.AMD64, Architecture.x86},
"arm": {Architecture.ARM64},
}
assert arch_set == expected[machine_name]
def test_arch_auto64(platform_machine):
platform_name, machine_name = platform_machine
arch_set = Architecture.parse_config("auto64", "linux")
expected = {"32": set(), "64": {Architecture.x86_64}, "arm": {Architecture.aarch64}}
assert arch_set == expected[machine_name]
arch_set = Architecture.parse_config("auto64", "macos")
expected = {"32": set(), "64": {Architecture.x86_64}, "arm": {Architecture.arm64}}
assert arch_set == expected[machine_name]
arch_set = Architecture.parse_config("auto64", "windows")
expected = {"32": set(), "64": {Architecture.AMD64}, "arm": {Architecture.ARM64}}
assert arch_set == expected[machine_name]
def test_arch_auto32(platform_machine):
platform_name, machine_name = platform_machine
arch_set = Architecture.parse_config("auto32", "linux")
expected = {"32": {Architecture.i686}, "64": {Architecture.i686}, "arm": set()}
assert arch_set == expected[machine_name]
arch_set = Architecture.parse_config("auto32", "macos")
assert arch_set == set()
arch_set = Architecture.parse_config("auto32", "windows")
expected = {"32": {Architecture.x86}, "64": {Architecture.x86}, "arm": set()}
assert arch_set == expected[machine_name]
+2 -1
View File
@@ -31,7 +31,8 @@ def mock_protection(monkeypatch):
""" """
def fail_on_call(*args, **kwargs): def fail_on_call(*args, **kwargs):
raise RuntimeError("This should never be called") msg = "This should never be called"
raise RuntimeError(msg)
def ignore_call(*args, **kwargs): def ignore_call(*args, **kwargs):
pass pass
+2 -1
View File
@@ -126,7 +126,8 @@ def get_default_repair_command(platform):
elif platform == "windows": elif platform == "windows":
return "" return ""
else: else:
raise ValueError("Unknown platform", platform) msg = f"Unknown platform: {platform!r}"
raise ValueError(msg)
@pytest.mark.parametrize("repair_command", [None, "repair", "repair -w {dest_dir} {wheel}"]) @pytest.mark.parametrize("repair_command", [None, "repair", "repair -w {dest_dir} {wheel}"])
@@ -199,6 +199,7 @@ def test_archs_platform_all(platform, intercepted_build_args, monkeypatch):
( (
("cp311-manylinux_x86_64", "linux"), ("cp311-manylinux_x86_64", "linux"),
("cp310-win_amd64", "windows"), ("cp310-win_amd64", "windows"),
("cp310-win32", "windows"),
("cp311-macosx_x86_64", "macos"), ("cp311-macosx_x86_64", "macos"),
), ),
) )
+2 -1
View File
@@ -19,7 +19,8 @@ ALL_IDS = {"cp36", "cp37", "cp38", "cp39", "cp310", "cp311", "pp37", "pp38", "pp
@pytest.fixture @pytest.fixture
def mock_build_container(monkeypatch): def mock_build_container(monkeypatch):
def fail_on_call(*args, **kwargs): def fail_on_call(*args, **kwargs):
raise RuntimeError("This should never be called") msg = "This should never be called"
raise RuntimeError(msg)
def ignore_call(*args, **kwargs): def ignore_call(*args, **kwargs):
pass pass