Compare commits

...
65 Commits
Author SHA1 Message Date
Joe Rickerby aa753429b2 Bump version: v2.6.1 2022-06-07 09:14:16 +01:00
dependabot[bot]anddependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> 45227e53e7 chore(deps): bump pre-commit/action from 2.0.3 to 3.0.0 (#1127)
Bumps [pre-commit/action](https://github.com/pre-commit/action) from 2.0.3 to 3.0.0.
- [Release notes](https://github.com/pre-commit/action/releases)
- [Commits](https://github.com/pre-commit/action/compare/v2.0.3...v3.0.0)

---
updated-dependencies:
- dependency-name: pre-commit/action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-06-06 18:56:34 +02:00
pre-commit-ci[bot]andpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> 0be10361af [pre-commit.ci] pre-commit autoupdate (#1120)
updates:
- [github.com/pre-commit/mirrors-mypy: v0.950 → v0.960](https://github.com/pre-commit/mirrors-mypy/compare/v0.950...v0.960)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-06-06 18:55:06 +02:00
cibuildwheel-bot[bot]andcibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com> a440ab3655 [Bot] Update dependencies (#1119)
Update dependencies

Co-authored-by: cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>
2022-06-06 15:53:13 +02:00
Matthieu Darbois c5c1766614 ci: disable travis-ci output timeout (#1123) 2022-06-04 20:03:02 +02:00
Joe Rickerby 4bbbee7949 Bump version: v2.6.0 2022-05-25 18:43:56 +01:00
Joe Rickerby d73f1ea2a4 Merge pull request #1109 from mayeut/python-3.11
feature: add CPython 3.11 support
2022-05-25 18:33:47 +01:00
Joe Rickerby a08a952b4b Merge pull request #1100 from pypa/docs-diagram
Add interactive diagram to the docs
2022-05-25 09:04:56 +01:00
pre-commit-ci[bot]andpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> 29f102bdfe [pre-commit.ci] pre-commit autoupdate (#1116)
updates:
- [github.com/hadialqattan/pycln: v1.3.2 → v1.3.3](https://github.com/hadialqattan/pycln/compare/v1.3.2...v1.3.3)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-05-24 12:13:13 -04:00
mayeut 2edd5270c3 mark CPython 3.11 as pre-release 2022-05-23 20:47:08 +02:00
mayeut b8abcb128c feature: add CPython 3.11 support 2022-05-23 20:47:08 +02:00
cibuildwheel-bot[bot]andcibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com> 79bfea0817 [Bot] Update dependencies (#1115)
Update dependencies

Co-authored-by: cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>
2022-05-23 20:44:09 +02:00
cibuildwheel-bot[bot]andcibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com> 0b1b47d7ec Update dependencies (#1111)
Co-authored-by: cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>
2022-05-16 17:48:27 -04:00
dependabot[bot]anddependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> a2a54b9833 chore(deps): bump excitedleigh/setup-nox from 2.0.0 to 2.1.0 (#1110)
Bumps [excitedleigh/setup-nox](https://github.com/excitedleigh/setup-nox) from 2.0.0 to 2.1.0.
- [Release notes](https://github.com/excitedleigh/setup-nox/releases)
- [Commits](https://github.com/excitedleigh/setup-nox/compare/v2.0.0...v2.1.0)

---
updated-dependencies:
- dependency-name: excitedleigh/setup-nox
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-16 18:26:58 +02:00
dependabot[bot] e33c037e6a chore(deps): bump docker/setup-qemu-action from 1 to 2 (#1106) 2022-05-10 07:51:24 +02:00
pre-commit-ci[bot] 7437ecf59d [pre-commit.ci] pre-commit autoupdate (#1107) 2022-05-10 07:51:05 +02:00
Joe Rickerby dcb5be78d0 Add noscript fallback 2022-05-09 14:24:03 +01:00
Joe Rickerby a37367fb86 Improve the touch support (tap the tooltip to follow link) 2022-05-09 13:31:47 +01:00
Matthieu Darbois 2d1ad70d06 chore: use bot email for dependency update Pull Requests (#1105) 2022-05-09 08:27:30 +02:00
pre-commit-ci[bot]andpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> 99d6c378db [pre-commit.ci] pre-commit autoupdate (#1102)
updates:
- [github.com/hadialqattan/pycln: v1.3.1 → v1.3.2](https://github.com/hadialqattan/pycln/compare/v1.3.1...v1.3.2)
- [github.com/pre-commit/mirrors-mypy: v0.942 → v0.950](https://github.com/pre-commit/mirrors-mypy/compare/v0.942...v0.950)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-05-07 20:42:17 -04:00
Joe Rickerby 960b069eb9 Add mobile/touch support (where hover doesn't exist) 2022-05-02 11:11:02 +01:00
Joe Rickerby 6d9a16376e Add interactive diagram to the docs 2022-04-30 17:14:21 +01:00
Joe Rickerby 1f1c8008d8 Changelog tweak 2022-04-29 14:54:25 +01:00
Joe Rickerby 0b6307072a Bump version: v2.5.0 2022-04-29 14:46:08 +01:00
Joe Rickerby 61bcac854e Merge pull request #1091 from mayeut/abi3
feature: add support for ABI3 wheels
2022-04-29 14:31:27 +01:00
Joe Rickerby 75998410e0 Add tips+tricks entry for ABI3 building 2022-04-29 14:16:00 +01:00
Joe Rickerby 46702f581d Space out the log statements a little 2022-04-29 13:32:03 +01:00
Joe Rickerby acc079675b Merge remote-tracking branch 'origin/main' into abi3 2022-04-29 11:57:20 +01:00
Joe Rickerby f324c9ad61 Merge pull request #1096 from henryiii/henryiii/feat/sdist
feat: SDist builds
2022-04-29 11:52:08 +01:00
Henry Schreiner de44c88c75 docs: add some projects (#1097)
* docs: add some projects

* chore: update docs
2022-04-28 19:18:49 -04:00
Henry Schreiner 35054666bb refactor: review comments 2022-04-27 17:18:01 -04:00
Henry Schreiner b1e8549bb1 fix: minor cleanup 2022-04-27 14:55:30 -04:00
Henry Schreiner 958a7c32c1 refactor: use single entry for SDist builds
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-04-27 09:37:17 -04:00
Joe Rickerby 91fae8268e Add prog arguments to ArgumentParser to prevent the wrong inferred name
when calling like 'python -m cibuildwheel', we get errors like

usage: __main__.py [-h] [--platform {auto,linux,macos,windows}] [--archs ARCHS] [--output-dir OUTPUT_DIR] [--config-file CONFIG_FILE]
                   [--print-build-identifiers] [--allow-empty] [--prerelease-pythons]
                   [package_dir]
__main__.py: error: unrecognized arguments: --sad

With this change, we get error outputs like:

usage: cibuildwheel [-h] [--platform {auto,linux,macos,windows}] [--archs ARCHS] [--output-dir OUTPUT_DIR] [--config-file CONFIG_FILE]
                    [--print-build-identifiers] [--allow-empty] [--prerelease-pythons]
                    [package_dir]
cibuildwheel: error: unrecognized arguments: --asda
2022-04-27 01:01:31 -04:00
Joe Rickerby 8c77d5ed41 Tidy ups, bug fixes 2022-04-27 01:01:31 -04:00
Joe Rickerby 898dd62022 Add test for argument passthrough 2022-04-27 01:01:31 -04:00
Joe Rickerby c6c5e6e59b Add test for cibuildwheel.from-sdist 2022-04-27 01:01:31 -04:00
Joe Rickerby e887d4bbf8 Add entrypoint 2022-04-27 01:01:31 -04:00
Joe Rickerby 763cd15ae2 Add from_sdist script 2022-04-27 01:01:31 -04:00
mayeut e3ff027131 feature: add support for ABI3 wheels 2022-04-26 22:38:17 +02:00
Matthieu Darbois de07370930 fix: extract project as current user on linux (#1095)
This allows git to work properly, e.g., `versioneer`/`setuptools_scm` with latest git versions.
c.f. https://github.com/pypa/manylinux/issues/1309
2022-04-26 13:29:00 -04:00
Henry Schreiner 986a50f8a0 docs: two minor additions (#1093)
* docs: mention when msvcd140_1.dll is included in cpython

* docs: mention maturin-action
2022-04-26 00:29:32 -04:00
Joe Rickerby dff69251ee Merge pull request #1086 from pauldmccarthy/bf/allow-empty
fix: Don't error if no new wheels were built
2022-04-22 10:47:56 +01:00
Paul McCarthy f08f08c04d style: spurious comma 2022-04-21 10:34:11 +01:00
pre-commit-ci[bot]andpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> 496ea9bd56 [pre-commit.ci] pre-commit autoupdate (#1092)
updates:
- [github.com/hadialqattan/pycln: v1.2.5 → v1.3.1](https://github.com/hadialqattan/pycln/compare/v1.2.5...v1.3.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-04-19 13:35:44 -04:00
Paul McCarthy abedb68783 test: build_frontend_env fixture not required for --allow-empy test. Small
style tweak
2022-04-19 16:02:23 +01:00
Paul McCarthy baf3ead650 style: exit early to reduce indentation 2022-04-19 16:00:12 +01:00
pre-commit-ci[bot] 30627ae04f [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2022-04-19 15:52:06 +01:00
Paul McCarthy 945d4f6635 test: don't modify build_frontend_env, as it appears to be global 2022-04-19 15:52:06 +01:00
pre-commit-ci[bot] d061fc7967 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2022-04-19 15:52:06 +01:00
Paul McCarthy be9a635f9b fix: don't assume that any configurations are active 2022-04-19 15:52:06 +01:00
Paul McCarthy bb2d5bdab6 TEST: Actually evaluate test outcome 2022-04-19 15:52:06 +01:00
pre-commit-ci[bot] 82c3d4a4b7 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2022-04-19 15:52:06 +01:00
Paul McCarthy 1f52f30fcf TEST: Sanity check test for --allow-empty flag 2022-04-19 15:52:06 +01:00
Paul McCarthy 1e176a021b RF: Remove unnecessary message 2022-04-19 15:52:06 +01:00
pre-commit-ci[bot] 07013d6baf [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2022-04-19 15:52:06 +01:00
Paul McCarthy fe97589390 fix: Don't error if no new wheels were built (this may happen if --allow-empty is active) 2022-04-19 15:52:06 +01:00
Shantanuandhauntsaninja <> 6d4431306e chore: use tomllib on Python 3.11 (#1047)
* Use tomllib on Python 3.11

* delint

Co-authored-by: hauntsaninja <>
2022-04-16 00:00:57 -04:00
pre-commit-ci[bot]pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>Henry Schreiner
9ae6ae2756 [pre-commit.ci] pre-commit autoupdate (#1084)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.1.0 → v4.2.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.1.0...v4.2.0)
- [github.com/asottile/pyupgrade: v2.31.1 → v2.32.0](https://github.com/asottile/pyupgrade/compare/v2.31.1...v2.32.0)

* chore: fix minor style msg

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

* chore: use extend on flake8

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-04-13 15:33:49 -04:00
dependabot[bot]anddependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> 00ba73bf21 chore(deps): bump actions/upload-artifact from 2 to 3 (#1082)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-12 15:15:01 -04:00
dependabot[bot]anddependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> 75fd65fcf7 chore(deps): bump actions/download-artifact from 2 to 3 (#1081)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-12 15:14:45 -04:00
Joe Rickerby 68b8cd8ee5 Merge pull request #1083 from DiddiLeija/fix-docs-py-block 2022-04-12 20:13:09 +01:00
Diego Ramirez a7271b2750 Fix a badly-formatted Python block in the docs
The whole block is indented, though a code block with Python formatting is there.
2022-04-11 12:45:38 -05:00
cibuildwheel-bot[bot]andmayeut 5824aecc5c Update dependencies (#1073)
Co-authored-by: mayeut <mayeut@users.noreply.github.com>
2022-04-05 00:53:56 -04:00
pre-commit-ci[bot]andpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> 989f21de16 [pre-commit.ci] pre-commit autoupdate (#1074)
updates:
- [github.com/asottile/setup-cfg-fmt: v1.20.0 → v1.20.1](https://github.com/asottile/setup-cfg-fmt/compare/v1.20.0...v1.20.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-04-05 00:53:33 -04:00
66 changed files with 1682 additions and 551 deletions
+2 -2
View File
@@ -16,7 +16,7 @@ jobs:
- name: Build SDist and wheel - name: Build SDist and wheel
run: pipx run build run: pipx run build
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v3
with: with:
path: dist/* path: dist/*
@@ -29,7 +29,7 @@ jobs:
if: github.event_name == 'release' && github.event.action == 'published' if: github.event_name == 'release' && github.event.action == 'published'
steps: steps:
- uses: actions/download-artifact@v2 - uses: actions/download-artifact@v3
with: with:
name: artifact name: artifact
path: dist path: dist
+3 -3
View File
@@ -21,7 +21,7 @@ jobs:
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: actions/setup-python@v3 - uses: actions/setup-python@v3
- uses: pre-commit/action@v2.0.3 - uses: pre-commit/action@v3.0.0
- name: Check manifest - name: Check manifest
run: pipx run nox -s check_manifest run: pipx run nox -s check_manifest
- name: PyLint checks - name: PyLint checks
@@ -61,7 +61,7 @@ jobs:
env: env:
CIBW_ARCHS_MACOS: x86_64 universal2 arm64 CIBW_ARCHS_MACOS: x86_64 universal2 arm64
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v3
with: with:
name: sample_wheels name: sample_wheels
path: wheelhouse path: wheelhouse
@@ -84,7 +84,7 @@ jobs:
- name: Set up QEMU - name: Set up QEMU
id: qemu id: qemu
uses: docker/setup-qemu-action@v1 uses: docker/setup-qemu-action@v2
with: with:
platforms: all platforms: all
+6 -1
View File
@@ -12,7 +12,10 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: excitedleigh/setup-nox@v2.0.0 - uses: actions/setup-python@v3
with:
python-version: "3.11-dev"
- uses: excitedleigh/setup-nox@v2.1.0
- name: "Run update: dependencies" - name: "Run update: dependencies"
run: nox --force-color -s update_constraints run: nox --force-color -s update_constraints
@@ -41,5 +44,7 @@ jobs:
PR generated by "Update dependencies" [workflow](https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}). PR generated by "Update dependencies" [workflow](https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}).
branch: update-dependencies-pr branch: update-dependencies-pr
committer: "cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>"
author: "cibuildwheel-bot[bot] <83877280+cibuildwheel-bot[bot]@users.noreply.github.com>"
token: ${{ steps.generate-token.outputs.token }} token: ${{ steps.generate-token.outputs.token }}
delete-branch: true delete-branch: true
+5 -5
View File
@@ -1,7 +1,7 @@
repos: repos:
- repo: https://github.com/pre-commit/pre-commit-hooks - repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0 rev: v4.2.0
hooks: hooks:
- id: check-case-conflict - id: check-case-conflict
- id: check-merge-conflict - id: check-merge-conflict
@@ -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.31.1 rev: v2.32.1
hooks: hooks:
- id: pyupgrade - id: pyupgrade
name: PyUpgrade 3.6+ name: PyUpgrade 3.6+
@@ -27,7 +27,7 @@ repos:
# Autoremoves unused imports # Autoremoves unused imports
- repo: https://github.com/hadialqattan/pycln - repo: https://github.com/hadialqattan/pycln
rev: v1.2.5 rev: v1.3.3
hooks: hooks:
- id: pycln - id: pycln
args: [--all] args: [--all]
@@ -44,12 +44,12 @@ repos:
- id: black - id: black
- repo: https://github.com/asottile/setup-cfg-fmt - repo: https://github.com/asottile/setup-cfg-fmt
rev: v1.20.0 rev: v1.20.1
hooks: hooks:
- id: setup-cfg-fmt - id: setup-cfg-fmt
- repo: https://github.com/pre-commit/mirrors-mypy - repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.942 rev: v0.960
hooks: hooks:
- id: mypy - id: mypy
name: mypy 3.6 on cibuildwheel/ name: mypy 3.6 on cibuildwheel/
+8 -1
View File
@@ -52,4 +52,11 @@ install:
- $PYTHON -m pip install -U pip - $PYTHON -m pip install -U pip
- $PYTHON -m pip install -e ".[dev]" pytest-custom-exit-code - $PYTHON -m pip install -e ".[dev]" pytest-custom-exit-code
script: $PYTHON ./bin/run_tests.py script: |
# travis_wait disable the output while waiting
# use the same kind of tricks as in multibuild
(while true; do echo "travis_keep_alive"; sleep 300; done) &
SPINNER_PID=$!
disown
$PYTHON ./bin/run_tests.py
kill -9 ${SPINNER_PID}
+47 -39
View File
@@ -29,6 +29,7 @@ What does it do?
| CPython 3.8 | ✅ | ✅ | ✅ | ✅ | N/A | ✅ | ✅ | ✅ | ✅ | ✅ | | CPython 3.8 | ✅ | ✅ | ✅ | ✅ | N/A | ✅ | ✅ | ✅ | ✅ | ✅ |
| CPython 3.9 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅³ | ✅ | ✅ | ✅ | ✅ | | CPython 3.9 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅³ | ✅ | ✅ | ✅ | ✅ |
| CPython 3.10 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ | | CPython 3.10 | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ |
| CPython 3.11⁴ | ✅ | ✅ | ✅ | ✅ | ✅² | ✅ | ✅ | ✅ | ✅ | ✅ |
| PyPy 3.7 v7.3 | ✅ | N/A | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A | | PyPy 3.7 v7.3 | ✅ | N/A | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A |
| PyPy 3.8 v7.3 | ✅ | N/A | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A | | PyPy 3.8 v7.3 | ✅ | 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 | | PyPy 3.9 v7.3 | ✅ | N/A | ✅ | N/A | N/A | ✅¹ | ✅¹ | ✅¹ | N/A | N/A |
@@ -36,6 +37,7 @@ What does it do?
<sup>¹ PyPy is only supported for manylinux wheels.</sup><br> <sup>¹ PyPy is only supported for manylinux wheels.</sup><br>
<sup>² Windows arm64 support is experimental.</sup><br> <sup>² Windows arm64 support is experimental.</sup><br>
<sup>³ Alpine 3.14 and very briefly 3.15's default python3 [was not able to load](https://github.com/pypa/cibuildwheel/issues/934) musllinux wheels. This has been fixed; please upgrade the python package if using Alpine from before the fix.</sup><br> <sup>³ Alpine 3.14 and very briefly 3.15's default python3 [was not able to load](https://github.com/pypa/cibuildwheel/issues/934) musllinux wheels. This has been fixed; please upgrade the python package if using Alpine from before the fix.</sup><br>
<sup>⁴ CPython 3.11 is available using the [CIBW_PRERELEASE_PYTHONS](https://cibuildwheel.readthedocs.io/en/stable/options/#prerelease-pythons) option.</sup><br>
- Builds manylinux, musllinux, macOS 10.9+, and Windows wheels for CPython and PyPy - Builds manylinux, musllinux, macOS 10.9+, and Windows wheels for CPython and PyPy
- Works on GitHub Actions, Azure Pipelines, Travis CI, AppVeyor, CircleCI, and GitLab CI - Works on GitHub Actions, Azure Pipelines, Travis CI, AppVeyor, CircleCI, and GitLab CI
@@ -87,7 +89,7 @@ jobs:
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
- name: Install cibuildwheel - name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.4.0 run: python -m pip install cibuildwheel==2.6.1
- name: Build wheels - name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse run: python -m cibuildwheel --output-dir wheelhouse
@@ -102,6 +104,15 @@ jobs:
For more information, including PyPI deployment, and the use of other CI services or the dedicated GitHub Action, check out the [documentation](https://cibuildwheel.readthedocs.org) and the [examples](https://github.com/pypa/cibuildwheel/tree/main/examples). For more information, including PyPI deployment, and the use of other CI services or the dedicated GitHub Action, check out the [documentation](https://cibuildwheel.readthedocs.org) and the [examples](https://github.com/pypa/cibuildwheel/tree/main/examples).
How it works
------------
The following diagram summarises the steps that cibuildwheel takes on each platform.
![](docs/data/how-it-works.png)
<sup>Explore an interactive version of this diagram [in the docs](https://cibuildwheel.readthedocs.io/en/stable/#how-it-works).</sup>
Options Options
------- -------
@@ -117,7 +128,7 @@ Options
| | [`CIBW_ENVIRONMENT_PASS_LINUX`](https://cibuildwheel.readthedocs.io/en/stable/options/#environment-pass) | Set environment variables on the host to pass-through to the container during the build. | | | [`CIBW_ENVIRONMENT_PASS_LINUX`](https://cibuildwheel.readthedocs.io/en/stable/options/#environment-pass) | Set environment variables on the host to pass-through to the container during the build. |
| | [`CIBW_BEFORE_ALL`](https://cibuildwheel.readthedocs.io/en/stable/options/#before-all) | Execute a shell command on the build system before any wheels are built. | | | [`CIBW_BEFORE_ALL`](https://cibuildwheel.readthedocs.io/en/stable/options/#before-all) | Execute a shell command on the build system before any wheels are built. |
| | [`CIBW_BEFORE_BUILD`](https://cibuildwheel.readthedocs.io/en/stable/options/#before-build) | Execute a shell command preparing each wheel's build | | | [`CIBW_BEFORE_BUILD`](https://cibuildwheel.readthedocs.io/en/stable/options/#before-build) | Execute a shell command preparing each wheel's build |
| | [`CIBW_REPAIR_WHEEL_COMMAND`](https://cibuildwheel.readthedocs.io/en/stable/options/#repair-wheel-command) | Execute a shell command to repair each (non-pure Python) built wheel | | | [`CIBW_REPAIR_WHEEL_COMMAND`](https://cibuildwheel.readthedocs.io/en/stable/options/#repair-wheel-command) | Execute a shell command to repair each built wheel |
| | [`CIBW_MANYLINUX_*_IMAGE`<br/>`CIBW_MUSLLINUX_*_IMAGE`](https://cibuildwheel.readthedocs.io/en/stable/options/#linux-image) | Specify alternative manylinux / musllinux Docker images | | | [`CIBW_MANYLINUX_*_IMAGE`<br/>`CIBW_MUSLLINUX_*_IMAGE`](https://cibuildwheel.readthedocs.io/en/stable/options/#linux-image) | Specify alternative manylinux / musllinux Docker images |
| | [`CIBW_DEPENDENCY_VERSIONS`](https://cibuildwheel.readthedocs.io/en/stable/options/#dependency-versions) | Specify how cibuildwheel controls the versions of the tools it uses | | | [`CIBW_DEPENDENCY_VERSIONS`](https://cibuildwheel.readthedocs.io/en/stable/options/#dependency-versions) | Specify how cibuildwheel controls the versions of the tools it uses |
| **Testing** | [`CIBW_TEST_COMMAND`](https://cibuildwheel.readthedocs.io/en/stable/options/#test-command) | Execute a shell command to test each built wheel | | **Testing** | [`CIBW_TEST_COMMAND`](https://cibuildwheel.readthedocs.io/en/stable/options/#test-command) | Execute a shell command to test each built wheel |
@@ -141,26 +152,26 @@ Here are some repos that use cibuildwheel.
| Name | CI | OS | Notes | | Name | CI | OS | Notes |
|-----------------------------------|----|----|:------| |-----------------------------------|----|----|:------|
| [scikit-learn][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The machine learning library. A complex but clean config using many of cibuildwheel's features to build a large project with Cython and C++ extensions. | | [scikit-learn][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The machine learning library. A complex but clean config using many of cibuildwheel's features to build a large project with Cython and C++ extensions. |
| [NumPy][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The fundamental package for scientific computing with Python. |
| [Tornado][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. | | [Tornado][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. |
| [pytorch-fairseq][] | ![github icon][] | ![apple icon][] ![linux icon][] | Facebook AI Research Sequence-to-Sequence Toolkit written in Python. | | [pytorch-fairseq][] | ![github icon][] | ![apple icon][] ![linux icon][] | Facebook AI Research Sequence-to-Sequence Toolkit written in Python. |
| [Matplotlib][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The venerable Matplotlib, a Python library with C++ portions | | [Matplotlib][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The venerable Matplotlib, a Python library with C++ portions |
| [MyPy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | MyPyC, the compiled component of MyPy. | | [NCNN][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | ncnn is a high-performance neural network inference framework optimized for the mobile platform |
| [Kivy][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Open source UI framework written in Python, running on Windows, Linux, macOS, Android and iOS |
| [Prophet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Tool for producing high quality forecasts for time series data that has multiple seasonality with linear or non-linear growth. |
| [MyPy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | The compiled version of MyPy using MyPyC. |
| [pydantic][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Data parsing and validation using Python type hints | | [pydantic][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Data parsing and validation using Python type hints |
| [uvloop][] | ![github icon][] | ![apple icon][] ![linux icon][] | Ultra fast asyncio event loop. |
| [psutil][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Cross-platform lib for process and system monitoring in Python |
| [vaex][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Out-of-Core hybrid Apache Arrow/NumPy DataFrame for Python, ML, visualization and exploration of big tabular data at a billion rows per second 🚀 |
| [Google Benchmark][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A microbenchmark support library |
[scikit-learn]: https://github.com/scikit-learn/scikit-learn [scikit-learn]: https://github.com/scikit-learn/scikit-learn
[NumPy]: https://github.com/numpy/numpy
[Tornado]: https://github.com/tornadoweb/tornado [Tornado]: https://github.com/tornadoweb/tornado
[pytorch-fairseq]: https://github.com/pytorch/fairseq [pytorch-fairseq]: https://github.com/pytorch/fairseq
[Matplotlib]: https://github.com/matplotlib/matplotlib [Matplotlib]: https://github.com/matplotlib/matplotlib
[NCNN]: https://github.com/Tencent/ncnn
[Kivy]: https://github.com/kivy/kivy
[Prophet]: https://github.com/facebook/prophet
[MyPy]: https://github.com/mypyc/mypy_mypyc-wheels [MyPy]: https://github.com/mypyc/mypy_mypyc-wheels
[pydantic]: https://github.com/samuelcolvin/pydantic [pydantic]: https://github.com/samuelcolvin/pydantic
[uvloop]: https://github.com/MagicStack/uvloop
[psutil]: https://github.com/giampaolo/psutil
[vaex]: https://github.com/vaexio/vaex
[Google Benchmark]: https://github.com/google/benchmark
[appveyor icon]: docs/data/readme_icons/appveyor.svg [appveyor icon]: docs/data/readme_icons/appveyor.svg
[github icon]: docs/data/readme_icons/github.svg [github icon]: docs/data/readme_icons/github.svg
@@ -192,6 +203,29 @@ 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.6.1
_7 June 2022_
- 🛠 Update the prerelease CPython 3.11 to 3.11.0b3
### v2.6.0
_25 May 2022_
- 🌟 Added the ability to test building wheels on CPython 3.11! Because CPython 3.11 is in beta, these wheels should not be distributed, because they might not be compatible with the final release, but it's available to build for testing purposes. Use the flag [`--prerelease-pythons` or `CIBW_PRERELEASE_PYTHONS`](https://cibuildwheel.readthedocs.io/en/stable/options/#prerelease-pythons) to test. This version of cibuildwheel includes CPython 3.11.0b1. (#1109)
- 📚 Added an interactive diagram showing how cibuildwheel works to the [docs](https://cibuildwheel.readthedocs.io/en/stable/#how-it-works) (#1100)
### v2.5.0
_29 April 2022_
- ✨ Added support for building ABI3 wheels. cibuildwheel will now recognise when an ABI3 wheel was produced, and skip subsequent build steps where the previously built wheel is compatible. Tests still will run on all selected versions of Python, using the ABI3 wheel. Check [this entry](https://cibuildwheel.readthedocs.io/en/stable/faq/#abi3) in the docs for more info. (#1091)
- ✨ You can now build wheels directly from sdist archives, in addition to source directories. Just call cibuildwheel with an sdist argument on the command line, like `cibuildwheel mypackage-1.0.0.tar.gz`. For more details, check the [`--help` output](https://cibuildwheel.readthedocs.io/en/stable/options/#command-line) (#1096)
- 🐛 Fix a bug where cibuildwheel would crash when no builds are selected and `--allow-empty` is passed (#1086)
- 🐛 Workaround a permissions issue on Linux relating to newer versions of git and setuptools_scm (#1095)
- 📚 Minor docs improvements
### v2.4.0 ### v2.4.0
_2 April 2022_ _2 April 2022_
@@ -212,32 +246,6 @@ _14 December 2021_
- 🐛 Setting pip options like `PIP_USE_DEPRECATED` in `CIBW_ENVIRONMENT` no longer adversely affects cibuildwheel's ability to set up a Python environment (#956) - 🐛 Setting pip options like `PIP_USE_DEPRECATED` in `CIBW_ENVIRONMENT` no longer adversely affects cibuildwheel's ability to set up a Python environment (#956)
- 📚 Docs fixes and improvements - 📚 Docs fixes and improvements
### v2.3.0
_26 November 2021_
- 📈 cibuildwheel now defaults to manylinux2014 image for linux builds, rather than manylinux2010. If you want to stick with manylinux2010, it's simple to set this using [the image options](https://cibuildwheel.readthedocs.io/en/stable/options/#linux-image). (#926)
- ✨ You can now pass environment variables from the host machine into the Docker container during a Linux build. Check out [the docs for `CIBW_ENVIRONMENT_PASS_LINUX `](https://cibuildwheel.readthedocs.io/en/latest/options/#environment-pass) for the details. (#914)
- ✨ Added support for building PyPy 3.8 wheels. (#881)
- ✨ Added support for building Windows arm64 CPython wheels on a Windows arm64 runner. We can't test this in CI yet, so for now, this is experimental. (#920)
- 📚 Improved the deployment documentation (#911)
- 🛠 Changed the escaping behaviour inside cibuildwheel's option placeholders e.g. `{project}` in `before_build` or `{dest_dir}` in `repair_wheel_command`. This allows bash syntax like `${SOME_VAR}` to passthrough without being interpreted as a placeholder by cibuildwheel. See [this section](https://cibuildwheel.readthedocs.io/en/stable/options/#placeholders) in the docs for more info. (#889)
- 🛠 Pip updated to 21.3, meaning it now defaults to in-tree builds again. If this causes an issue with your project, setting environment variable `PIP_USE_DEPRECATED=out-of-tree-build` is available as a temporary flag to restore the old behaviour. However, be aware that this flag will probably be removed soon. (#881)
- 🐛 You can now access the current Python interpreter using `python3` within a build on Windows (#917)
### v2.2.2
_26 October 2021_
- 🐛 Fix bug in the GitHub Action step causing a syntax error (#895)
### v2.2.1
_26 October 2021_
- 🛠 Added a `config-file` option on the GitHub Action to specify something other than pyproject.toml in your GitHub Workflow file. (#883)
- 🐛 Fix missing resources in sdist and released wheel on PyPI. We've also made some internal changes to our release processes to make them more reliable. (#893, #894)
<!-- END bin/update_readme_changelog.py --> <!-- END bin/update_readme_changelog.py -->
--- ---
@@ -283,6 +291,6 @@ Massive props also to-
See also See also
======== ========
If you'd like to keep wheel building separate from the package itself, check out [astrofrog/autowheel](https://github.com/astrofrog/autowheel). It builds packages using cibuildwheel from source distributions on PyPI.
Another very similar tool to consider is [matthew-brett/multibuild](http://github.com/matthew-brett/multibuild). `multibuild` is a shell script toolbox for building a wheel on various platforms. It is used as a basis to build some of the big data science tools, like SciPy. Another very similar tool to consider is [matthew-brett/multibuild](http://github.com/matthew-brett/multibuild). `multibuild` is a shell script toolbox for building a wheel on various platforms. It is used as a basis to build some of the big data science tools, like SciPy.
If you are building Rust wheels, you can get by without some of the tricks required to make GLIBC work via manylinux; this is especially relevant for cross-compiling, which is easy with Rust. See [maturin-action](https://github.com/messense/maturin-action) for a tool that is optimized for building Rust wheels and cross-compiling.
+8 -2
View File
@@ -5,13 +5,19 @@ from __future__ import annotations
import copy import copy
import difflib import difflib
import logging import logging
import sys
from pathlib import Path from pathlib import Path
from typing import Any, Union from typing import Any, Union
import click import click
import requests import requests
import rich import rich
import tomli
if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from packaging.specifiers import Specifier from packaging.specifiers import Specifier
from packaging.version import Version from packaging.version import Version
from rich.logging import RichHandler from rich.logging import RichHandler
@@ -296,7 +302,7 @@ def update_pythons(force: bool, level: str) -> None:
original_toml = toml_file_path.read_text() original_toml = toml_file_path.read_text()
with toml_file_path.open("rb") as f: with toml_file_path.open("rb") as f:
configs = tomli.load(f) configs = tomllib.load(f)
for config in configs["windows"]["python_configurations"]: for config in configs["windows"]["python_configurations"]:
all_versions.update_config(config) all_versions.update_config(config)
+8 -2
View File
@@ -5,12 +5,18 @@ from __future__ import annotations
import difflib import difflib
import logging import logging
import subprocess import subprocess
import sys
from pathlib import Path from pathlib import Path
from typing import NamedTuple from typing import NamedTuple
import click import click
import rich import rich
import tomli
if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from packaging.version import InvalidVersion, Version from packaging.version import InvalidVersion, Version
from rich.logging import RichHandler from rich.logging import RichHandler
from rich.syntax import Syntax from rich.syntax import Syntax
@@ -78,7 +84,7 @@ def update_virtualenv(force: bool, level: str) -> None:
original_toml = toml_file_path.read_text() original_toml = toml_file_path.read_text()
with toml_file_path.open("rb") as f: with toml_file_path.open("rb") as f:
loaded_file = tomli.load(f) loaded_file = tomllib.load(f)
version = str(loaded_file["version"]) version = str(loaded_file["version"])
versions = git_ls_remote_versions(GET_VIRTUALENV_GITHUB) versions = git_ls_remote_versions(GET_VIRTUALENV_GITHUB)
if versions[0].version > Version(version): if versions[0].version > Version(version):
+1 -1
View File
@@ -1 +1 @@
__version__ = "2.4.0" __version__ = "2.6.1"
+50 -9
View File
@@ -2,6 +2,8 @@ import argparse
import os import os
import shutil import shutil
import sys import sys
import tarfile
import tempfile
import textwrap import textwrap
from pathlib import Path from pathlib import Path
from tempfile import mkdtemp from tempfile import mkdtemp
@@ -20,13 +22,12 @@ from cibuildwheel.util import (
CIBW_CACHE_PATH, CIBW_CACHE_PATH,
BuildSelector, BuildSelector,
Unbuffered, Unbuffered,
chdir,
detect_ci_provider, detect_ci_provider,
) )
def main() -> None: def main() -> None:
platform: PlatformName
parser = argparse.ArgumentParser( parser = argparse.ArgumentParser(
description="Build wheels for all the platforms.", description="Build wheels for all the platforms.",
epilog=""" epilog="""
@@ -65,6 +66,8 @@ def main() -> None:
parser.add_argument( parser.add_argument(
"--output-dir", "--output-dir",
type=Path,
default=Path(os.environ.get("CIBW_OUTPUT_DIR", "wheelhouse")),
help="Destination folder for the wheels. Default: wheelhouse.", help="Destination folder for the wheels. Default: wheelhouse.",
) )
@@ -72,20 +75,26 @@ def main() -> None:
"--config-file", "--config-file",
default="", default="",
help=""" help="""
TOML config file. Default: "", meaning {package}/pyproject.toml, TOML config file. Default: "", meaning {package}/pyproject.toml, if
if it exists. it exists. To refer to a project inside your project, use {package};
this matters if you build from an SDist.
""", """,
) )
parser.add_argument( parser.add_argument(
"package_dir", "package_dir",
default=".", metavar="PACKAGE",
default=Path("."),
type=Path,
nargs="?", nargs="?",
help=""" help="""
Path to the package that you want wheels for. Must be a subdirectory of Path to the package that you want wheels for. Default: the working
the working directory. When set, the working directory is still directory. Can be a directory inside the working directory, or an
considered the 'project' and is copied into the Docker container on sdist. When set to a directory, the working directory is still
Linux. Default: the working directory. considered the 'project' and is copied into the Docker container
on Linux. When set to a tar.gz sdist file, --config-file
and --output-dir are relative to the current directory, and other
paths are relative to the expanded SDist directory.
""", """,
) )
@@ -109,6 +118,38 @@ def main() -> None:
args = parser.parse_args(namespace=CommandLineArguments()) args = parser.parse_args(namespace=CommandLineArguments())
args.package_dir = args.package_dir.resolve()
# This are always relative to the base directory, even in SDist builds
args.output_dir = args.output_dir.resolve()
# Standard builds if a directory or non-existent path is given
if not args.package_dir.is_file() and not args.package_dir.name.endswith("tar.gz"):
build_in_directory(args)
return
# Tarfile builds require extraction and changing the directory
with tempfile.TemporaryDirectory(prefix="cibw-sdist-") as temp_dir_str:
temp_dir = Path(temp_dir_str)
with tarfile.open(args.package_dir) as tar:
tar.extractall(path=temp_dir)
# The extract directory is now the project dir
try:
(project_dir,) = temp_dir.iterdir()
except ValueError:
raise SystemExit("invalid sdist: didn't contain a single dir") from None
# This is now the new package dir
args.package_dir = project_dir.resolve()
with chdir(temp_dir):
build_in_directory(args)
def build_in_directory(args: CommandLineArguments) -> None:
platform: PlatformName
if args.platform != "auto": if args.platform != "auto":
platform = args.platform platform = args.platform
else: else:
+1 -1
View File
@@ -122,7 +122,7 @@ class DockerContainer:
if from_path.is_dir(): if from_path.is_dir():
self.call(["mkdir", "-p", to_path]) self.call(["mkdir", "-p", to_path])
subprocess.run( subprocess.run(
f"tar cf - . | docker exec -i {self.name} tar -xC {shell_quote(to_path)} -f -", f"tar cf - . | docker exec -i {self.name} tar --no-same-owner -xC {shell_quote(to_path)} -f -",
shell=True, shell=True,
check=True, check=True,
cwd=from_path, cwd=from_path,
-1
View File
@@ -51,7 +51,6 @@ class EnvironmentAssignment(Protocol):
executor: Optional[bashlex_eval.EnvironmentExecutor] = None, executor: Optional[bashlex_eval.EnvironmentExecutor] = None,
) -> str: ) -> str:
"""Returns the value of this assignment, as evaluated in the environment""" """Returns the value of this assignment, as evaluated in the environment"""
...
class EnvironmentAssignmentRaw: class EnvironmentAssignmentRaw:
+79 -63
View File
@@ -12,6 +12,7 @@ from .typing import OrderedDict, PathOrStr, assert_never
from .util import ( from .util import (
BuildSelector, BuildSelector,
NonPlatformWheelError, NonPlatformWheelError,
find_compatible_abi3_wheel,
get_build_verbosity_extra_flags, get_build_verbosity_extra_flags,
prepare_command, prepare_command,
read_python_configs, read_python_configs,
@@ -132,6 +133,8 @@ def build_on_docker(
) )
docker.call(["sh", "-c", before_all_prepared], env=env) docker.call(["sh", "-c", before_all_prepared], env=env)
built_wheels: List[PurePath] = []
for config in platform_configs: for config in platform_configs:
log.build_start(config.identifier) log.build_start(config.identifier)
build_options = options.build_options(config.identifier) build_options = options.build_options(config.identifier)
@@ -174,74 +177,83 @@ def build_on_docker(
) )
sys.exit(1) sys.exit(1)
if build_options.before_build: abi3_wheel = find_compatible_abi3_wheel(built_wheels, config.identifier)
log.step("Running before_build...") if abi3_wheel:
before_build_prepared = prepare_command( log.step_end()
build_options.before_build, print(
project=container_project_path, f"\nFound previously built wheel {abi3_wheel.name}, that's compatible with {config.identifier}. Skipping build step..."
package=container_package_dir,
)
docker.call(["sh", "-c", before_build_prepared], env=env)
log.step("Building wheel...")
temp_dir = PurePath("/tmp/cibuildwheel")
built_wheel_dir = temp_dir / "built_wheel"
docker.call(["rm", "-rf", built_wheel_dir])
docker.call(["mkdir", "-p", built_wheel_dir])
verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity)
if build_options.build_frontend == "pip":
docker.call(
[
"python",
"-m",
"pip",
"wheel",
container_package_dir,
f"--wheel-dir={built_wheel_dir}",
"--no-deps",
*verbosity_flags,
],
env=env,
)
elif build_options.build_frontend == "build":
config_setting = " ".join(verbosity_flags)
docker.call(
[
"python",
"-m",
"build",
container_package_dir,
"--wheel",
f"--outdir={built_wheel_dir}",
f"--config-setting={config_setting}",
],
env=env,
) )
repaired_wheels = [abi3_wheel]
else: else:
assert_never(build_options.build_frontend)
built_wheel = docker.glob(built_wheel_dir, "*.whl")[0] if build_options.before_build:
log.step("Running before_build...")
before_build_prepared = prepare_command(
build_options.before_build,
project=container_project_path,
package=container_package_dir,
)
docker.call(["sh", "-c", before_build_prepared], env=env)
repaired_wheel_dir = temp_dir / "repaired_wheel" log.step("Building wheel...")
docker.call(["rm", "-rf", repaired_wheel_dir])
docker.call(["mkdir", "-p", repaired_wheel_dir])
if built_wheel.name.endswith("none-any.whl"): temp_dir = PurePath("/tmp/cibuildwheel")
raise NonPlatformWheelError() built_wheel_dir = temp_dir / "built_wheel"
docker.call(["rm", "-rf", built_wheel_dir])
docker.call(["mkdir", "-p", built_wheel_dir])
if build_options.repair_command: verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity)
log.step("Repairing wheel...")
repair_command_prepared = prepare_command(
build_options.repair_command, wheel=built_wheel, dest_dir=repaired_wheel_dir
)
docker.call(["sh", "-c", repair_command_prepared], env=env)
else:
docker.call(["mv", built_wheel, repaired_wheel_dir])
repaired_wheels = docker.glob(repaired_wheel_dir, "*.whl") if build_options.build_frontend == "pip":
docker.call(
[
"python",
"-m",
"pip",
"wheel",
container_package_dir,
f"--wheel-dir={built_wheel_dir}",
"--no-deps",
*verbosity_flags,
],
env=env,
)
elif build_options.build_frontend == "build":
config_setting = " ".join(verbosity_flags)
docker.call(
[
"python",
"-m",
"build",
container_package_dir,
"--wheel",
f"--outdir={built_wheel_dir}",
f"--config-setting={config_setting}",
],
env=env,
)
else:
assert_never(build_options.build_frontend)
built_wheel = docker.glob(built_wheel_dir, "*.whl")[0]
repaired_wheel_dir = temp_dir / "repaired_wheel"
docker.call(["rm", "-rf", repaired_wheel_dir])
docker.call(["mkdir", "-p", repaired_wheel_dir])
if built_wheel.name.endswith("none-any.whl"):
raise NonPlatformWheelError()
if build_options.repair_command:
log.step("Repairing wheel...")
repair_command_prepared = prepare_command(
build_options.repair_command, wheel=built_wheel, dest_dir=repaired_wheel_dir
)
docker.call(["sh", "-c", repair_command_prepared], env=env)
else:
docker.call(["mv", built_wheel, repaired_wheel_dir])
repaired_wheels = docker.glob(repaired_wheel_dir, "*.whl")
if build_options.test_command and build_options.test_selector(config.identifier): if build_options.test_command and build_options.test_selector(config.identifier):
log.step("Testing wheel...") log.step("Testing wheel...")
@@ -292,8 +304,12 @@ def build_on_docker(
docker.call(["rm", "-rf", venv_dir]) docker.call(["rm", "-rf", venv_dir])
# move repaired wheels to output # move repaired wheels to output
docker.call(["mkdir", "-p", container_output_dir]) if abi3_wheel is None:
docker.call(["mv", *repaired_wheels, container_output_dir]) docker.call(["mkdir", "-p", container_output_dir])
docker.call(["mv", *repaired_wheels, container_output_dir])
built_wheels.extend(
container_output_dir / repaired_wheel.name for repaired_wheel in repaired_wheels
)
log.build_end() log.build_end()
+88 -70
View File
@@ -23,6 +23,7 @@ from .util import (
call, call,
detect_ci_provider, detect_ci_provider,
download, download,
find_compatible_abi3_wheel,
get_build_verbosity_extra_flags, get_build_verbosity_extra_flags,
get_pip_version, get_pip_version,
install_certifi_script, install_certifi_script,
@@ -275,6 +276,9 @@ def build(options: Options, tmp_path: Path) -> None:
options.globals.build_selector, options.globals.architectures options.globals.build_selector, options.globals.architectures
) )
if len(python_configurations) == 0:
return
try: try:
before_all_options_identifier = python_configurations[0].identifier before_all_options_identifier = python_configurations[0].identifier
before_all_options = options.build_options(before_all_options_identifier) before_all_options = options.build_options(before_all_options_identifier)
@@ -288,6 +292,8 @@ def build(options: Options, tmp_path: Path) -> None:
) )
shell(before_all_prepared, env=env) shell(before_all_prepared, env=env)
built_wheels: List[Path] = []
for config in python_configurations: for config in python_configurations:
build_options = options.build_options(config.identifier) build_options = options.build_options(config.identifier)
log.build_start(config.identifier) log.build_start(config.identifier)
@@ -315,84 +321,94 @@ def build(options: Options, tmp_path: Path) -> None:
build_options.build_frontend, build_options.build_frontend,
) )
if build_options.before_build: abi3_wheel = find_compatible_abi3_wheel(built_wheels, config.identifier)
log.step("Running before_build...") if abi3_wheel:
before_build_prepared = prepare_command( log.step_end()
build_options.before_build, project=".", package=build_options.package_dir print(
f"\nFound previously built wheel {abi3_wheel.name}, that's compatible with {config.identifier}. Skipping build step..."
) )
shell(before_build_prepared, env=env) repaired_wheel = abi3_wheel
else:
log.step("Building wheel...") if build_options.before_build:
built_wheel_dir.mkdir() log.step("Running before_build...")
before_build_prepared = prepare_command(
verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity) build_options.before_build, project=".", package=build_options.package_dir
if build_options.build_frontend == "pip":
# Path.resolve() is needed. Without it pip wheel may try to fetch package from pypi.org
# see https://github.com/pypa/cibuildwheel/pull/369
call(
"python",
"-m",
"pip",
"wheel",
build_options.package_dir.resolve(),
f"--wheel-dir={built_wheel_dir}",
"--no-deps",
*verbosity_flags,
env=env,
)
elif build_options.build_frontend == "build":
config_setting = " ".join(verbosity_flags)
build_env = env.copy()
if build_options.dependency_constraints:
constraint_path = build_options.dependency_constraints.get_for_python_version(
config.version
) )
build_env["PIP_CONSTRAINT"] = constraint_path.as_uri() shell(before_build_prepared, env=env)
build_env["VIRTUALENV_PIP"] = get_pip_version(env)
call(
"python",
"-m",
"build",
build_options.package_dir,
"--wheel",
f"--outdir={built_wheel_dir}",
f"--config-setting={config_setting}",
env=build_env,
)
else:
assert_never(build_options.build_frontend)
built_wheel = next(built_wheel_dir.glob("*.whl")) log.step("Building wheel...")
built_wheel_dir.mkdir()
repaired_wheel_dir.mkdir() verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity)
if built_wheel.name.endswith("none-any.whl"): if build_options.build_frontend == "pip":
raise NonPlatformWheelError() # Path.resolve() is needed. Without it pip wheel may try to fetch package from pypi.org
# see https://github.com/pypa/cibuildwheel/pull/369
if build_options.repair_command: call(
log.step("Repairing wheel...") "python",
"-m",
if config_is_universal2: "pip",
delocate_archs = "x86_64,arm64" "wheel",
elif config_is_arm64: build_options.package_dir.resolve(),
delocate_archs = "arm64" f"--wheel-dir={built_wheel_dir}",
"--no-deps",
*verbosity_flags,
env=env,
)
elif build_options.build_frontend == "build":
config_setting = " ".join(verbosity_flags)
build_env = env.copy()
if build_options.dependency_constraints:
constraint_path = (
build_options.dependency_constraints.get_for_python_version(
config.version
)
)
build_env["PIP_CONSTRAINT"] = constraint_path.as_uri()
build_env["VIRTUALENV_PIP"] = get_pip_version(env)
call(
"python",
"-m",
"build",
build_options.package_dir,
"--wheel",
f"--outdir={built_wheel_dir}",
f"--config-setting={config_setting}",
env=build_env,
)
else: else:
delocate_archs = "x86_64" assert_never(build_options.build_frontend)
repair_command_prepared = prepare_command( built_wheel = next(built_wheel_dir.glob("*.whl"))
build_options.repair_command,
wheel=built_wheel,
dest_dir=repaired_wheel_dir,
delocate_archs=delocate_archs,
)
shell(repair_command_prepared, env=env)
else:
shutil.move(str(built_wheel), repaired_wheel_dir)
repaired_wheel = next(repaired_wheel_dir.glob("*.whl")) repaired_wheel_dir.mkdir()
log.step_end() if built_wheel.name.endswith("none-any.whl"):
raise NonPlatformWheelError()
if build_options.repair_command:
log.step("Repairing wheel...")
if config_is_universal2:
delocate_archs = "x86_64,arm64"
elif config_is_arm64:
delocate_archs = "arm64"
else:
delocate_archs = "x86_64"
repair_command_prepared = prepare_command(
build_options.repair_command,
wheel=built_wheel,
dest_dir=repaired_wheel_dir,
delocate_archs=delocate_archs,
)
shell(repair_command_prepared, env=env)
else:
shutil.move(str(built_wheel), repaired_wheel_dir)
repaired_wheel = next(repaired_wheel_dir.glob("*.whl"))
log.step_end()
if build_options.test_command and build_options.test_selector(config.identifier): if build_options.test_command and build_options.test_selector(config.identifier):
machine_arch = platform.machine() machine_arch = platform.machine()
@@ -518,7 +534,9 @@ def build(options: Options, tmp_path: Path) -> None:
) )
# we're all done here; move it to output (overwrite existing) # we're all done here; move it to output (overwrite existing)
shutil.move(str(repaired_wheel), build_options.output_dir) if abi3_wheel is None:
shutil.move(str(repaired_wheel), build_options.output_dir)
built_wheels.append(build_options.output_dir / repaired_wheel.name)
# clean up # clean up
shutil.rmtree(identifier_tmp_dir) shutil.rmtree(identifier_tmp_dir)
+14 -13
View File
@@ -8,7 +8,7 @@ from pathlib import Path
from typing import ( from typing import (
Any, Any,
Dict, Dict,
Iterator, Generator,
List, List,
Mapping, Mapping,
NamedTuple, NamedTuple,
@@ -18,7 +18,11 @@ from typing import (
Union, Union,
) )
import tomli if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from packaging.specifiers import SpecifierSet from packaging.specifiers import SpecifierSet
from .architecture import Architecture from .architecture import Architecture
@@ -33,6 +37,7 @@ from .util import (
DependencyConstraints, DependencyConstraints,
TestSelector, TestSelector,
cached_property, cached_property,
format_safe,
resources_dir, resources_dir,
selector_matches, selector_matches,
strtobool, strtobool,
@@ -43,9 +48,9 @@ from .util import (
class CommandLineArguments: class CommandLineArguments:
platform: Literal["auto", "linux", "macos", "windows"] platform: Literal["auto", "linux", "macos", "windows"]
archs: Optional[str] archs: Optional[str]
output_dir: Optional[str] output_dir: Path
config_file: str config_file: str
package_dir: str package_dir: Path
print_build_identifiers: bool print_build_identifiers: bool
allow_empty: bool allow_empty: bool
prerelease_pythons: bool prerelease_pythons: bool
@@ -244,7 +249,7 @@ class OptionsReader:
Load a toml file, returns global and platform as separate dicts. Load a toml file, returns global and platform as separate dicts.
""" """
with filename.open("rb") as f: with filename.open("rb") as f:
config = tomli.load(f) config = tomllib.load(f)
global_options = config.get("tool", {}).get("cibuildwheel", {}) global_options = config.get("tool", {}).get("cibuildwheel", {})
platform_options = global_options.get(self.platform, {}) platform_options = global_options.get(self.platform, {})
@@ -260,7 +265,7 @@ class OptionsReader:
] ]
@contextmanager @contextmanager
def identifier(self, identifier: Optional[str]) -> Iterator[None]: def identifier(self, identifier: Optional[str]) -> Generator[None, None, None]:
self.current_identifier = identifier self.current_identifier = identifier
try: try:
yield yield
@@ -341,7 +346,7 @@ class Options:
args = self.command_line_arguments args = self.command_line_arguments
if args.config_file: if args.config_file:
return Path(args.config_file.format(package=args.package_dir)) return Path(format_safe(args.config_file, package=args.package_dir))
# return pyproject.toml, if it's available # return pyproject.toml, if it's available
pyproject_toml_path = Path(args.package_dir) / "pyproject.toml" pyproject_toml_path = Path(args.package_dir) / "pyproject.toml"
@@ -358,12 +363,8 @@ class Options:
@property @property
def globals(self) -> GlobalOptions: def globals(self) -> GlobalOptions:
args = self.command_line_arguments args = self.command_line_arguments
package_dir = Path(args.package_dir) package_dir = args.package_dir
output_dir = Path( output_dir = args.output_dir
args.output_dir
if args.output_dir is not None
else os.environ.get("CIBW_OUTPUT_DIR", "wheelhouse")
)
build_config = self.reader.get("build", env_plat=False, sep=" ") or "*" build_config = self.reader.get("build", env_plat=False, sep=" ") or "*"
skip_config = self.reader.get("skip", env_plat=False, sep=" ") skip_config = self.reader.get("skip", env_plat=False, sep=" ")
+5 -2
View File
@@ -4,7 +4,10 @@ from configparser import ConfigParser
from pathlib import Path from pathlib import Path
from typing import Any, Optional from typing import Any, Optional
import tomli if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
if sys.version_info < (3, 8): if sys.version_info < (3, 8):
Constant = ast.Str Constant = ast.Str
@@ -56,7 +59,7 @@ def get_requires_python_str(package_dir: Path) -> Optional[str]:
# Read in from pyproject.toml:project.requires-python # Read in from pyproject.toml:project.requires-python
try: try:
with (package_dir / "pyproject.toml").open("rb") as f1: with (package_dir / "pyproject.toml").open("rb") as f1:
info = tomli.load(f1) info = tomllib.load(f1)
return str(info["project"]["requires-python"]) return str(info["project"]["requires-python"])
except (FileNotFoundError, KeyError, IndexError, TypeError): except (FileNotFoundError, KeyError, IndexError, TypeError):
pass pass
+21 -5
View File
@@ -5,11 +5,13 @@ python_configurations = [
{ identifier = "cp38-manylinux_x86_64", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-manylinux_x86_64", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-manylinux_x86_64", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-manylinux_x86_64", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-manylinux_x86_64", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-manylinux_x86_64", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-manylinux_x86_64", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-manylinux_i686", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-manylinux_i686", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-manylinux_i686", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-manylinux_i686", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-manylinux_i686", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-manylinux_i686", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-manylinux_i686", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-manylinux_i686", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-manylinux_i686", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-manylinux_i686", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-manylinux_i686", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "pp37-manylinux_x86_64", version = "3.7", path_str = "/opt/python/pp37-pypy37_pp73" }, { identifier = "pp37-manylinux_x86_64", version = "3.7", path_str = "/opt/python/pp37-pypy37_pp73" },
{ identifier = "pp38-manylinux_x86_64", version = "3.8", path_str = "/opt/python/pp38-pypy38_pp73" }, { identifier = "pp38-manylinux_x86_64", version = "3.8", path_str = "/opt/python/pp38-pypy38_pp73" },
{ identifier = "pp39-manylinux_x86_64", version = "3.9", path_str = "/opt/python/pp39-pypy39_pp73" }, { identifier = "pp39-manylinux_x86_64", version = "3.9", path_str = "/opt/python/pp39-pypy39_pp73" },
@@ -18,16 +20,19 @@ python_configurations = [
{ identifier = "cp38-manylinux_aarch64", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-manylinux_aarch64", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-manylinux_aarch64", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-manylinux_aarch64", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-manylinux_aarch64", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-manylinux_aarch64", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-manylinux_aarch64", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-manylinux_ppc64le", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-manylinux_ppc64le", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-manylinux_ppc64le", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-manylinux_ppc64le", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-manylinux_ppc64le", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-manylinux_ppc64le", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-manylinux_ppc64le", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-manylinux_ppc64le", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-manylinux_ppc64le", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-manylinux_ppc64le", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-manylinux_ppc64le", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-manylinux_s390x", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-manylinux_s390x", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-manylinux_s390x", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-manylinux_s390x", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-manylinux_s390x", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-manylinux_s390x", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-manylinux_s390x", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-manylinux_s390x", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-manylinux_s390x", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-manylinux_s390x", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-manylinux_s390x", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "pp37-manylinux_aarch64", version = "3.7", path_str = "/opt/python/pp37-pypy37_pp73" }, { identifier = "pp37-manylinux_aarch64", version = "3.7", path_str = "/opt/python/pp37-pypy37_pp73" },
{ identifier = "pp38-manylinux_aarch64", version = "3.8", path_str = "/opt/python/pp38-pypy38_pp73" }, { identifier = "pp38-manylinux_aarch64", version = "3.8", path_str = "/opt/python/pp38-pypy38_pp73" },
{ identifier = "pp39-manylinux_aarch64", version = "3.9", path_str = "/opt/python/pp39-pypy39_pp73" }, { identifier = "pp39-manylinux_aarch64", version = "3.9", path_str = "/opt/python/pp39-pypy39_pp73" },
@@ -39,26 +44,31 @@ python_configurations = [
{ identifier = "cp38-musllinux_x86_64", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-musllinux_x86_64", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-musllinux_x86_64", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-musllinux_x86_64", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-musllinux_x86_64", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-musllinux_x86_64", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-musllinux_x86_64", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-musllinux_i686", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-musllinux_i686", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-musllinux_i686", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-musllinux_i686", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-musllinux_i686", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-musllinux_i686", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-musllinux_i686", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-musllinux_i686", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-musllinux_i686", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-musllinux_i686", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-musllinux_i686", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-musllinux_aarch64", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-musllinux_aarch64", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-musllinux_aarch64", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-musllinux_aarch64", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-musllinux_aarch64", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-musllinux_aarch64", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-musllinux_aarch64", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-musllinux_aarch64", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-musllinux_aarch64", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-musllinux_aarch64", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-musllinux_aarch64", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-musllinux_ppc64le", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-musllinux_ppc64le", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-musllinux_ppc64le", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-musllinux_ppc64le", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-musllinux_ppc64le", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-musllinux_ppc64le", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-musllinux_ppc64le", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-musllinux_ppc64le", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-musllinux_ppc64le", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-musllinux_ppc64le", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-musllinux_ppc64le", version = "3.11", path_str = "/opt/python/cp311-cp311" },
{ identifier = "cp36-musllinux_s390x", version = "3.6", path_str = "/opt/python/cp36-cp36m" }, { identifier = "cp36-musllinux_s390x", version = "3.6", path_str = "/opt/python/cp36-cp36m" },
{ identifier = "cp37-musllinux_s390x", version = "3.7", path_str = "/opt/python/cp37-cp37m" }, { identifier = "cp37-musllinux_s390x", version = "3.7", path_str = "/opt/python/cp37-cp37m" },
{ identifier = "cp38-musllinux_s390x", version = "3.8", path_str = "/opt/python/cp38-cp38" }, { identifier = "cp38-musllinux_s390x", version = "3.8", path_str = "/opt/python/cp38-cp38" },
{ identifier = "cp39-musllinux_s390x", version = "3.9", path_str = "/opt/python/cp39-cp39" }, { identifier = "cp39-musllinux_s390x", version = "3.9", path_str = "/opt/python/cp39-cp39" },
{ identifier = "cp310-musllinux_s390x", version = "3.10", path_str = "/opt/python/cp310-cp310" }, { identifier = "cp310-musllinux_s390x", version = "3.10", path_str = "/opt/python/cp310-cp310" },
{ identifier = "cp311-musllinux_s390x", version = "3.11", path_str = "/opt/python/cp311-cp311" },
] ]
[macos] [macos]
@@ -68,12 +78,15 @@ python_configurations = [
{ identifier = "cp38-macosx_x86_64", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" }, { identifier = "cp38-macosx_x86_64", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" },
{ identifier = "cp38-macosx_arm64", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" }, { identifier = "cp38-macosx_arm64", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" },
{ identifier = "cp38-macosx_universal2", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" }, { identifier = "cp38-macosx_universal2", version = "3.8", url = "https://www.python.org/ftp/python/3.8.10/python-3.8.10-macosx10.9.pkg" },
{ identifier = "cp39-macosx_x86_64", version = "3.9", url = "https://www.python.org/ftp/python/3.9.12/python-3.9.12-macos11.pkg" }, { identifier = "cp39-macosx_x86_64", version = "3.9", url = "https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg" },
{ identifier = "cp39-macosx_arm64", version = "3.9", url = "https://www.python.org/ftp/python/3.9.12/python-3.9.12-macos11.pkg" }, { identifier = "cp39-macosx_arm64", version = "3.9", url = "https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg" },
{ identifier = "cp39-macosx_universal2", version = "3.9", url = "https://www.python.org/ftp/python/3.9.12/python-3.9.12-macos11.pkg" }, { identifier = "cp39-macosx_universal2", version = "3.9", url = "https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg" },
{ identifier = "cp310-macosx_x86_64", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" }, { identifier = "cp310-macosx_x86_64", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" },
{ identifier = "cp310-macosx_arm64", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" }, { identifier = "cp310-macosx_arm64", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" },
{ identifier = "cp310-macosx_universal2", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" }, { identifier = "cp310-macosx_universal2", version = "3.10", url = "https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg" },
{ identifier = "cp311-macosx_x86_64", version = "3.11", url = "https://www.python.org/ftp/python/3.11.0/python-3.11.0b3-macos11.pkg" },
{ identifier = "cp311-macosx_arm64", version = "3.11", url = "https://www.python.org/ftp/python/3.11.0/python-3.11.0b3-macos11.pkg" },
{ identifier = "cp311-macosx_universal2", version = "3.11", url = "https://www.python.org/ftp/python/3.11.0/python-3.11.0b3-macos11.pkg" },
{ identifier = "pp37-macosx_x86_64", version = "3.7", url = "https://downloads.python.org/pypy/pypy3.7-v7.3.9-osx64.tar.bz2" }, { identifier = "pp37-macosx_x86_64", version = "3.7", url = "https://downloads.python.org/pypy/pypy3.7-v7.3.9-osx64.tar.bz2" },
{ identifier = "pp38-macosx_x86_64", version = "3.8", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.9-osx64.tar.bz2" }, { identifier = "pp38-macosx_x86_64", version = "3.8", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.9-osx64.tar.bz2" },
{ identifier = "pp39-macosx_x86_64", version = "3.9", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.9-osx64.tar.bz2" }, { identifier = "pp39-macosx_x86_64", version = "3.9", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.9-osx64.tar.bz2" },
@@ -87,12 +100,15 @@ python_configurations = [
{ identifier = "cp37-win_amd64", version = "3.7.9", arch = "64" }, { identifier = "cp37-win_amd64", version = "3.7.9", arch = "64" },
{ identifier = "cp38-win32", version = "3.8.10", arch = "32" }, { identifier = "cp38-win32", version = "3.8.10", arch = "32" },
{ identifier = "cp38-win_amd64", version = "3.8.10", arch = "64" }, { identifier = "cp38-win_amd64", version = "3.8.10", arch = "64" },
{ identifier = "cp39-win32", version = "3.9.12", arch = "32" }, { identifier = "cp39-win32", version = "3.9.13", arch = "32" },
{ identifier = "cp39-win_amd64", version = "3.9.12", arch = "64" }, { identifier = "cp39-win_amd64", version = "3.9.13", arch = "64" },
{ identifier = "cp310-win32", version = "3.10.4", arch = "32" }, { identifier = "cp310-win32", version = "3.10.4", arch = "32" },
{ identifier = "cp310-win_amd64", version = "3.10.4", arch = "64" }, { identifier = "cp310-win_amd64", version = "3.10.4", arch = "64" },
{ identifier = "cp311-win32", version = "3.11.0-b3", arch = "32" },
{ identifier = "cp311-win_amd64", version = "3.11.0-b3", arch = "64" },
{ identifier = "cp39-win_arm64", version = "3.9.10", arch = "ARM64" }, { identifier = "cp39-win_arm64", version = "3.9.10", arch = "ARM64" },
{ identifier = "cp310-win_arm64", version = "3.10.4", arch = "ARM64" }, { identifier = "cp310-win_arm64", version = "3.10.4", arch = "ARM64" },
{ identifier = "cp311-win_arm64", version = "3.11.0-b3", arch = "ARM64" },
{ identifier = "pp37-win_amd64", version = "3.7", arch = "64", url = "https://downloads.python.org/pypy/pypy3.7-v7.3.9-win64.zip" }, { identifier = "pp37-win_amd64", version = "3.7", arch = "64", url = "https://downloads.python.org/pypy/pypy3.7-v7.3.9-win64.zip" },
{ identifier = "pp38-win_amd64", version = "3.8", arch = "64", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.9-win64.zip" }, { identifier = "pp38-win_amd64", version = "3.8", arch = "64", url = "https://downloads.python.org/pypy/pypy3.8-v7.3.9-win64.zip" },
{ identifier = "pp39-win_amd64", version = "3.9", arch = "64", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.9-win64.zip" }, { identifier = "pp39-win_amd64", version = "3.9", arch = "64", url = "https://downloads.python.org/pypy/pypy3.9-v7.3.9-win64.zip" },
@@ -8,15 +8,15 @@ delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
distlib==0.3.4 distlib==0.3.4
# via virtualenv # via virtualenv
filelock==3.6.0 filelock==3.7.1
# via virtualenv # via virtualenv
platformdirs==2.5.1 platformdirs==2.5.2
# via virtualenv # via virtualenv
six==1.16.0 six==1.16.0
# via virtualenv # via virtualenv
typing-extensions==4.1.1 typing-extensions==4.2.0
# via delocate # via delocate
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
@@ -24,7 +24,7 @@ wheel==0.37.1
# delocate # delocate
# The following packages are considered to be unsafe in a requirements file: # The following packages are considered to be unsafe in a requirements file:
pip==22.0.4 pip==22.1.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
setuptools==61.3.0 setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
@@ -0,0 +1,30 @@
#
# This file is autogenerated by pip-compile with python 3.11
# To update, run:
#
# bin/update_dependencies.py
#
delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in
distlib==0.3.4
# via virtualenv
filelock==3.7.1
# via virtualenv
platformdirs==2.5.2
# via virtualenv
six==1.16.0
# via virtualenv
typing-extensions==4.2.0
# via delocate
virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in
wheel==0.37.1
# via
# -r cibuildwheel/resources/constraints.in
# delocate
# The following packages are considered to be unsafe in a requirements file:
pip==22.1.2
# via -r cibuildwheel/resources/constraints.in
setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in
@@ -22,7 +22,7 @@ typing-extensions==4.1.1
# via # via
# delocate # delocate
# importlib-metadata # importlib-metadata
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
@@ -8,29 +8,29 @@ delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
distlib==0.3.4 distlib==0.3.4
# via virtualenv # via virtualenv
filelock==3.6.0 filelock==3.7.1
# via virtualenv # via virtualenv
importlib-metadata==4.11.3 importlib-metadata==4.11.4
# via virtualenv # via virtualenv
platformdirs==2.5.1 platformdirs==2.5.2
# via virtualenv # via virtualenv
six==1.16.0 six==1.16.0
# via virtualenv # via virtualenv
typing-extensions==4.1.1 typing-extensions==4.2.0
# via # via
# delocate # delocate
# importlib-metadata # importlib-metadata
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
# -r cibuildwheel/resources/constraints.in # -r cibuildwheel/resources/constraints.in
# delocate # delocate
zipp==3.7.0 zipp==3.8.0
# via importlib-metadata # via importlib-metadata
# The following packages are considered to be unsafe in a requirements file: # The following packages are considered to be unsafe in a requirements file:
pip==22.0.4 pip==22.1.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
setuptools==61.3.0 setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
@@ -8,15 +8,15 @@ delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
distlib==0.3.4 distlib==0.3.4
# via virtualenv # via virtualenv
filelock==3.6.0 filelock==3.7.1
# via virtualenv # via virtualenv
platformdirs==2.5.1 platformdirs==2.5.2
# via virtualenv # via virtualenv
six==1.16.0 six==1.16.0
# via virtualenv # via virtualenv
typing-extensions==4.1.1 typing-extensions==4.2.0
# via delocate # via delocate
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
@@ -24,7 +24,7 @@ wheel==0.37.1
# delocate # delocate
# The following packages are considered to be unsafe in a requirements file: # The following packages are considered to be unsafe in a requirements file:
pip==22.0.4 pip==22.1.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
setuptools==61.3.0 setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
@@ -8,15 +8,15 @@ delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
distlib==0.3.4 distlib==0.3.4
# via virtualenv # via virtualenv
filelock==3.6.0 filelock==3.7.1
# via virtualenv # via virtualenv
platformdirs==2.5.1 platformdirs==2.5.2
# via virtualenv # via virtualenv
six==1.16.0 six==1.16.0
# via virtualenv # via virtualenv
typing-extensions==4.1.1 typing-extensions==4.2.0
# via delocate # via delocate
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
@@ -24,7 +24,7 @@ wheel==0.37.1
# delocate # delocate
# The following packages are considered to be unsafe in a requirements file: # The following packages are considered to be unsafe in a requirements file:
pip==22.0.4 pip==22.1.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
setuptools==61.3.0 setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
+6 -6
View File
@@ -8,15 +8,15 @@ delocate==0.10.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
distlib==0.3.4 distlib==0.3.4
# via virtualenv # via virtualenv
filelock==3.6.0 filelock==3.7.1
# via virtualenv # via virtualenv
platformdirs==2.5.1 platformdirs==2.5.2
# via virtualenv # via virtualenv
six==1.16.0 six==1.16.0
# via virtualenv # via virtualenv
typing-extensions==4.1.1 typing-extensions==4.2.0
# via delocate # via delocate
virtualenv==20.14.0 virtualenv==20.14.1
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
wheel==0.37.1 wheel==0.37.1
# via # via
@@ -24,7 +24,7 @@ wheel==0.37.1
# delocate # delocate
# The following packages are considered to be unsafe in a requirements file: # The following packages are considered to be unsafe in a requirements file:
pip==22.0.4 pip==22.1.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
setuptools==61.3.0 setuptools==62.3.2
# via -r cibuildwheel/resources/constraints.in # via -r cibuildwheel/resources/constraints.in
+27 -27
View File
@@ -1,43 +1,43 @@
[x86_64] [x86_64]
manylinux1 = quay.io/pypa/manylinux1_x86_64:2022-03-31-9afae1d manylinux1 = quay.io/pypa/manylinux1_x86_64:2022-06-05-89b8e6d
manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-03-31-361e6b6 manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-06-05-61145a4
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-06-05-61145a4
musllinux_1_1 = quay.io/pypa/musllinux_1_1_x86_64:2022-03-31-361e6b6 musllinux_1_1 = quay.io/pypa/musllinux_1_1_x86_64:2022-06-05-61145a4
[i686] [i686]
manylinux1 = quay.io/pypa/manylinux1_i686:2022-03-31-9afae1d manylinux1 = quay.io/pypa/manylinux1_i686:2022-06-05-89b8e6d
manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-03-31-361e6b6 manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-06-05-61145a4
manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-06-05-61145a4
musllinux_1_1 = quay.io/pypa/musllinux_1_1_i686:2022-03-31-361e6b6 musllinux_1_1 = quay.io/pypa/musllinux_1_1_i686:2022-06-05-61145a4
[pypy_x86_64] [pypy_x86_64]
manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-03-31-361e6b6 manylinux2010 = quay.io/pypa/manylinux2010_x86_64:2022-06-05-61145a4
manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_x86_64:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_x86_64:2022-06-05-61145a4
[pypy_i686] [pypy_i686]
manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-03-31-361e6b6 manylinux2010 = quay.io/pypa/manylinux2010_i686:2022-06-05-61145a4
manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_i686:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_i686:2022-06-05-61145a4
[aarch64] [aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-06-05-61145a4
musllinux_1_1 = quay.io/pypa/musllinux_1_1_aarch64:2022-03-31-361e6b6 musllinux_1_1 = quay.io/pypa/musllinux_1_1_aarch64:2022-06-05-61145a4
[ppc64le] [ppc64le]
manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_ppc64le:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_ppc64le:2022-06-05-61145a4
musllinux_1_1 = quay.io/pypa/musllinux_1_1_ppc64le:2022-03-31-361e6b6 musllinux_1_1 = quay.io/pypa/musllinux_1_1_ppc64le:2022-06-05-61145a4
[s390x] [s390x]
manylinux2014 = quay.io/pypa/manylinux2014_s390x:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_s390x:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_s390x:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_s390x:2022-06-05-61145a4
musllinux_1_1 = quay.io/pypa/musllinux_1_1_s390x:2022-03-31-361e6b6 musllinux_1_1 = quay.io/pypa/musllinux_1_1_s390x:2022-06-05-61145a4
[pypy_aarch64] [pypy_aarch64]
manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-03-31-361e6b6 manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2022-06-05-61145a4
manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-03-31-361e6b6 manylinux_2_24 = quay.io/pypa/manylinux_2_24_aarch64:2022-06-05-61145a4
+2 -2
View File
@@ -1,2 +1,2 @@
version = "20.13.3" version = "20.14.1"
url = "https://github.com/pypa/get-virtualenv/blob/20.13.3/public/virtualenv.pyz?raw=true" url = "https://github.com/pypa/get-virtualenv/blob/20.14.1/public/virtualenv.pyz?raw=true"
+70 -7
View File
@@ -13,29 +13,37 @@ import time
import urllib.request import urllib.request
from enum import Enum from enum import Enum
from functools import lru_cache from functools import lru_cache
from pathlib import Path from pathlib import Path, PurePath
from time import sleep from time import sleep
from typing import ( from typing import (
Any, Any,
ClassVar, ClassVar,
Dict, Dict,
Generator,
Iterable, Iterable,
Iterator,
List, List,
NamedTuple, NamedTuple,
Optional, Optional,
Sequence, Sequence,
TextIO, TextIO,
TypeVar,
Union,
cast, cast,
overload, overload,
) )
import bracex import bracex
import certifi import certifi
import tomli
if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from filelock import FileLock from filelock import FileLock
from packaging.requirements import InvalidRequirement, Requirement from packaging.requirements import InvalidRequirement, Requirement
from packaging.specifiers import SpecifierSet from packaging.specifiers import SpecifierSet
from packaging.utils import parse_wheel_filename
from packaging.version import Version from packaging.version import Version
from platformdirs import user_cache_path from platformdirs import user_cache_path
@@ -46,6 +54,7 @@ __all__ = [
"MANYLINUX_ARCHS", "MANYLINUX_ARCHS",
"call", "call",
"shell", "shell",
"find_compatible_abi3_wheel",
"format_safe", "format_safe",
"prepare_command", "prepare_command",
"get_build_verbosity_extra_flags", "get_build_verbosity_extra_flags",
@@ -53,6 +62,7 @@ __all__ = [
"selector_matches", "selector_matches",
"strtobool", "strtobool",
"cached_property", "cached_property",
"chdir",
] ]
resources_dir: Final = Path(__file__).parent / "resources" resources_dir: Final = Path(__file__).parent / "resources"
@@ -203,7 +213,7 @@ def get_build_verbosity_extra_flags(level: int) -> List[str]:
def read_python_configs(config: PlatformName) -> List[Dict[str, str]]: def read_python_configs(config: PlatformName) -> List[Dict[str, str]]:
input_file = resources_dir / "build-platforms.toml" input_file = resources_dir / "build-platforms.toml"
with input_file.open("rb") as f: with input_file.open("rb") as f:
loaded_file = tomli.load(f) loaded_file = tomllib.load(f)
results: List[Dict[str, str]] = list(loaded_file[config]["python_configurations"]) results: List[Dict[str, str]] = list(loaded_file[config]["python_configurations"])
return results return results
@@ -234,7 +244,7 @@ class IdentifierSelector:
""" """
# a pattern that skips prerelease versions, when include_prereleases is False. # a pattern that skips prerelease versions, when include_prereleases is False.
PRERELEASE_SKIP: ClassVar[str] = "" PRERELEASE_SKIP: ClassVar[str] = "cp311-*"
skip_config: str skip_config: str
build_config: str build_config: str
@@ -409,7 +419,7 @@ def unwrap(text: str) -> str:
@contextlib.contextmanager @contextlib.contextmanager
def print_new_wheels(msg: str, output_dir: Path) -> Iterator[None]: def print_new_wheels(msg: str, output_dir: Path) -> Generator[None, None, None]:
""" """
Prints the new items in a directory upon exiting. The message to display Prints the new items in a directory upon exiting. The message to display
can include {n} for number of wheels, {s} for total number of seconds, can include {n} for number of wheels, {s} for total number of seconds,
@@ -430,6 +440,10 @@ def print_new_wheels(msg: str, output_dir: Path) -> Iterator[None]:
FileReport(wheel.name, f"{(wheel.stat().st_size + 1023) // 1024:,d}") FileReport(wheel.name, f"{(wheel.stat().st_size + 1023) // 1024:,d}")
for wheel in final_contents - existing_contents for wheel in final_contents - existing_contents
] ]
if len(new_contents) == 0:
return
max_name_len = max(len(f.name) for f in new_contents) max_name_len = max(len(f.name) for f in new_contents)
max_size_len = max(len(f.size) for f in new_contents) max_size_len = max(len(f.size) for f in new_contents)
n = len(new_contents) n = len(new_contents)
@@ -460,7 +474,7 @@ def get_pip_version(env: Dict[str, str]) -> str:
def _ensure_virtualenv() -> Path: def _ensure_virtualenv() -> Path:
input_file = resources_dir / "virtualenv.toml" input_file = resources_dir / "virtualenv.toml"
with input_file.open("rb") as f: with input_file.open("rb") as f:
loaded_file = tomli.load(f) loaded_file = tomllib.load(f)
version = str(loaded_file["version"]) version = str(loaded_file["version"])
url = str(loaded_file["url"]) url = str(loaded_file["url"])
path = CIBW_CACHE_PATH / f"virtualenv-{version}.pyz" path = CIBW_CACHE_PATH / f"virtualenv-{version}.pyz"
@@ -557,7 +571,56 @@ def virtualenv(
return env return env
T = TypeVar("T", bound=PurePath)
def find_compatible_abi3_wheel(wheels: Sequence[T], identifier: str) -> Optional[T]:
"""
Finds an ABI3 wheel in `wheels` compatible with the Python interpreter
specified by `identifier`.
"""
interpreter, platform = identifier.split("-")
if not interpreter.startswith("cp3"):
return None
for wheel in wheels:
_, _, _, tags = parse_wheel_filename(wheel.name)
for tag in tags:
if tag.abi != "abi3":
continue
if not tag.interpreter.startswith("cp3"):
continue
if int(tag.interpreter[3:]) > int(interpreter[3:]):
continue
if platform.startswith(("manylinux", "musllinux", "macosx")):
# Linux, macOS
os_, arch = platform.split("_", 1)
if not tag.platform.startswith(os_):
continue
if not tag.platform.endswith("_" + arch):
continue
else:
# Windows
if not tag.platform == platform:
continue
return wheel
return None
if sys.version_info >= (3, 8): if sys.version_info >= (3, 8):
from functools import cached_property from functools import cached_property
else: else:
from .functools_cached_property_38 import cached_property from .functools_cached_property_38 import cached_property
# Can be replaced by contextlib.chdir in Python 3.11
@contextlib.contextmanager
def chdir(new_path: Union[Path, str]) -> Generator[None, None, None]:
"""Non thread-safe context manager to change the current working directory."""
cwd = os.getcwd()
try:
os.chdir(new_path)
yield
finally:
os.chdir(cwd)
+84 -66
View File
@@ -22,6 +22,7 @@ from .util import (
NonPlatformWheelError, NonPlatformWheelError,
call, call,
download, download,
find_compatible_abi3_wheel,
get_build_verbosity_extra_flags, get_build_verbosity_extra_flags,
get_pip_version, get_pip_version,
prepare_command, prepare_command,
@@ -234,6 +235,9 @@ def build(options: Options, tmp_path: Path) -> None:
options.globals.build_selector, options.globals.architectures options.globals.build_selector, options.globals.architectures
) )
if len(python_configurations) == 0:
return
try: try:
before_all_options_identifier = python_configurations[0].identifier before_all_options_identifier = python_configurations[0].identifier
before_all_options = options.build_options(before_all_options_identifier) before_all_options = options.build_options(before_all_options_identifier)
@@ -246,6 +250,8 @@ def build(options: Options, tmp_path: Path) -> None:
) )
shell(before_all_prepared, env=env) shell(before_all_prepared, env=env)
built_wheels: List[Path] = []
for config in python_configurations: for config in python_configurations:
build_options = options.build_options(config.identifier) build_options = options.build_options(config.identifier)
log.build_start(config.identifier) log.build_start(config.identifier)
@@ -271,83 +277,93 @@ def build(options: Options, tmp_path: Path) -> None:
build_options.build_frontend, build_options.build_frontend,
) )
# run the before_build command abi3_wheel = find_compatible_abi3_wheel(built_wheels, config.identifier)
if build_options.before_build: if abi3_wheel:
log.step("Running before_build...") log.step_end()
before_build_prepared = prepare_command( print(
build_options.before_build, project=".", package=options.globals.package_dir f"\nFound previously built wheel {abi3_wheel.name}, that's compatible with {config.identifier}. Skipping build step..."
) )
shell(before_build_prepared, env=env) repaired_wheel = abi3_wheel
else:
log.step("Building wheel...") # run the before_build command
built_wheel_dir.mkdir() if build_options.before_build:
log.step("Running before_build...")
verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity) before_build_prepared = prepare_command(
build_options.before_build, project=".", package=options.globals.package_dir
if build_options.build_frontend == "pip":
# Path.resolve() is needed. Without it pip wheel may try to fetch package from pypi.org
# see https://github.com/pypa/cibuildwheel/pull/369
call(
"python",
"-m",
"pip",
"wheel",
options.globals.package_dir.resolve(),
f"--wheel-dir={built_wheel_dir}",
"--no-deps",
*get_build_verbosity_extra_flags(build_options.build_verbosity),
env=env,
)
elif build_options.build_frontend == "build":
config_setting = " ".join(verbosity_flags)
build_env = env.copy()
if build_options.dependency_constraints:
constraints_path = build_options.dependency_constraints.get_for_python_version(
config.version
) )
# Bug in pip <= 21.1.3 - we can't have a space in the shell(before_build_prepared, env=env)
# constraints file, and pip doesn't support drive letters
# in uhi. After probably pip 21.2, we can use uri. For
# now, use a temporary file.
if " " in str(constraints_path):
assert " " not in str(identifier_tmp_dir)
tmp_file = identifier_tmp_dir / "constraints.txt"
tmp_file.write_bytes(constraints_path.read_bytes())
constraints_path = tmp_file
build_env["PIP_CONSTRAINT"] = str(constraints_path) log.step("Building wheel...")
build_env["VIRTUALENV_PIP"] = get_pip_version(env) built_wheel_dir.mkdir()
verbosity_flags = get_build_verbosity_extra_flags(build_options.build_verbosity)
if build_options.build_frontend == "pip":
# Path.resolve() is needed. Without it pip wheel may try to fetch package from pypi.org
# see https://github.com/pypa/cibuildwheel/pull/369
call( call(
"python", "python",
"-m", "-m",
"build", "pip",
build_options.package_dir, "wheel",
"--wheel", options.globals.package_dir.resolve(),
f"--outdir={built_wheel_dir}", f"--wheel-dir={built_wheel_dir}",
f"--config-setting={config_setting}", "--no-deps",
env=build_env, *get_build_verbosity_extra_flags(build_options.build_verbosity),
env=env,
) )
else: elif build_options.build_frontend == "build":
assert_never(build_options.build_frontend) config_setting = " ".join(verbosity_flags)
build_env = env.copy()
if build_options.dependency_constraints:
constraints_path = (
build_options.dependency_constraints.get_for_python_version(
config.version
)
)
# Bug in pip <= 21.1.3 - we can't have a space in the
# constraints file, and pip doesn't support drive letters
# in uhi. After probably pip 21.2, we can use uri. For
# now, use a temporary file.
if " " in str(constraints_path):
assert " " not in str(identifier_tmp_dir)
tmp_file = identifier_tmp_dir / "constraints.txt"
tmp_file.write_bytes(constraints_path.read_bytes())
constraints_path = tmp_file
built_wheel = next(built_wheel_dir.glob("*.whl")) build_env["PIP_CONSTRAINT"] = str(constraints_path)
build_env["VIRTUALENV_PIP"] = get_pip_version(env)
call(
"python",
"-m",
"build",
build_options.package_dir,
"--wheel",
f"--outdir={built_wheel_dir}",
f"--config-setting={config_setting}",
env=build_env,
)
else:
assert_never(build_options.build_frontend)
# repair the wheel built_wheel = next(built_wheel_dir.glob("*.whl"))
repaired_wheel_dir.mkdir()
if built_wheel.name.endswith("none-any.whl"): # repair the wheel
raise NonPlatformWheelError() repaired_wheel_dir.mkdir()
if build_options.repair_command: if built_wheel.name.endswith("none-any.whl"):
log.step("Repairing wheel...") raise NonPlatformWheelError()
repair_command_prepared = prepare_command(
build_options.repair_command, wheel=built_wheel, dest_dir=repaired_wheel_dir
)
shell(repair_command_prepared, env=env)
else:
shutil.move(str(built_wheel), repaired_wheel_dir)
repaired_wheel = next(repaired_wheel_dir.glob("*.whl")) if build_options.repair_command:
log.step("Repairing wheel...")
repair_command_prepared = prepare_command(
build_options.repair_command, wheel=built_wheel, dest_dir=repaired_wheel_dir
)
shell(repair_command_prepared, env=env)
else:
shutil.move(str(built_wheel), repaired_wheel_dir)
repaired_wheel = next(repaired_wheel_dir.glob("*.whl"))
if build_options.test_command and options.globals.test_selector(config.identifier): if build_options.test_command and options.globals.test_selector(config.identifier):
log.step("Testing wheel...") log.step("Testing wheel...")
@@ -402,7 +418,9 @@ def build(options: Options, tmp_path: Path) -> None:
shell(test_command_prepared, cwd="c:\\", env=virtualenv_env) shell(test_command_prepared, cwd="c:\\", env=virtualenv_env)
# we're all done here; move it to output (remove if already exists) # we're all done here; move it to output (remove if already exists)
shutil.move(str(repaired_wheel), build_options.output_dir) if abi3_wheel is None:
shutil.move(str(repaired_wheel), build_options.output_dir)
built_wheels.append(build_options.output_dir / repaired_wheel.name)
# clean up # clean up
# (we ignore errors because occasionally Windows fails to unlink a file and we # (we ignore errors because occasionally Windows fails to unlink a file and we
+23
View File
@@ -2,6 +2,29 @@
title: Changelog title: Changelog
--- ---
### v2.6.1
_7 June 2022_
- 🛠 Update the prerelease CPython 3.11 to 3.11.0b3
### v2.6.0
_25 May 2022_
- 🌟 Added the ability to test building wheels on CPython 3.11! Because CPython 3.11 is in beta, these wheels should not be distributed, because they might not be compatible with the final release, but it's available to build for testing purposes. Use the flag [`--prerelease-pythons` or `CIBW_PRERELEASE_PYTHONS`](https://cibuildwheel.readthedocs.io/en/stable/options/#prerelease-pythons) to test. This version of cibuildwheel includes CPython 3.11.0b1. (#1109)
- 📚 Added an interactive diagram showing how cibuildwheel works to the [docs](https://cibuildwheel.readthedocs.io/en/stable/#how-it-works) (#1100)
### v2.5.0
_29 April 2022_
- ✨ Added support for building ABI3 wheels. cibuildwheel will now recognise when an ABI3 wheel was produced, and skip subsequent build steps where the previously built wheel is compatible. Tests still will run on all selected versions of Python, using the ABI3 wheel. Check [this entry](https://cibuildwheel.readthedocs.io/en/stable/faq/#abi3) in the docs for more info. (#1091)
- ✨ You can now build wheels directly from sdist archives, in addition to source directories. Just call cibuildwheel with an sdist argument on the command line, like `cibuildwheel mypackage-1.0.0.tar.gz`. For more details, check the [`--help` output](https://cibuildwheel.readthedocs.io/en/stable/options/#command-line) (#1096)
- 🐛 Fix a bug where cibuildwheel would crash when no builds are selected and `--allow-empty` is passed (#1086)
- 🐛 Workaround a permissions issue on Linux relating to newer versions of git and setuptools_scm (#1095)
- 📚 Minor docs improvements
### v2.4.0 ### v2.4.0
_2 April 2022_ _2 April 2022_
+1 -1
View File
@@ -14,7 +14,7 @@ The old `manylinux1` image (based on CentOS 5) contains a version of GCC and lib
OS X/macOS allows you to specify a so-called "deployment target" version that will ensure backwards compatibility with older versions of macOS. One way to do this is by setting the `MACOSX_DEPLOYMENT_TARGET` environment variable. OS X/macOS allows you to specify a so-called "deployment target" version that will ensure backwards compatibility with older versions of macOS. One way to do this is by setting the `MACOSX_DEPLOYMENT_TARGET` environment variable.
However, to enable modern C++ standards, the deploment target needs to be set high enough (since older OS X/macOS versions did not have the necessary modern C++ standard library). However, to enable modern C++ standards, the deployment target needs to be set high enough (since older OS X/macOS versions did not have the necessary modern C++ standard library).
To get C++11 and C++14 support, `MACOSX_DEPLOYMENT_TARGET` needs to be set to (at least) `"10.9"`. By default, `cibuildwheel` already does this, building 64-bit-only wheels for macOS 10.9 and later. To get C++11 and C++14 support, `MACOSX_DEPLOYMENT_TARGET` needs to be set to (at least) `"10.9"`. By default, `cibuildwheel` already does this, building 64-bit-only wheels for macOS 10.9 and later.
Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

+63 -2
View File
@@ -287,7 +287,7 @@
pypi: mypy pypi: mypy
ci: [github] ci: [github]
os: [apple, linux, windows] os: [apple, linux, windows]
notes: MyPyC, the compiled component of MyPy. notes: The compiled version of MyPy using MyPyC.
- name: Imagecodecs (fork) - name: Imagecodecs (fork)
gh: czaki/imagecodecs_build gh: czaki/imagecodecs_build
@@ -521,10 +521,71 @@
gh: arbor-sim/arbor gh: arbor-sim/arbor
ci: [github] ci: [github]
os: [apple, linux] os: [apple, linux]
pypi: arbor
notes: > notes: >
Arbor is a multi-compartment neuron simulation library; compatible with Arbor is a multi-compartment neuron simulation library; compatible with
next-generation accelerators; best-practices applied to research software; next-generation accelerators; best-practices applied to research software;
focused on community-driven development. Includes a focused on community-driven development. Includes a
[small script](https://github.com/arbor-sim/arbor/blob/master/scripts/patchwheel.py) [small script](https://github.com/arbor-sim/arbor/blob/master/scripts/patchwheel.py)
patching `rpath` in bundled libraries. patching `rpath` in bundled libraries.
- name: Kivy
gh: kivy/kivy
ci: [github]
os: [windows, apple, linux]
- name: NCNN
gh: Tencent/ncnn
ci: [github]
os: [windows, apple, linux]
- name: Prophet
gh: facebook/prophet
ci: [github]
os: [windows, apple, linux]
- name: MemRay
gh: bloomberg/memray
ci: [github]
os: [linux]
- name: PyGame
gh: pygame/pygame
ci: [github]
os: [apple, linux]
- name: UltraJSON
gh: ultrajson/ultrajson
ci: [github]
os: [windows, apple, linux]
- name: NumPy
gh: numpy/numpy
ci: [github, travisci]
os: [windows, apple, linux]
- name: Wrapt
gh: GrahamDumpleton/wrapt
ci: [github]
os: [windows, apple, linux]
- name: SimpleJSON
gh: simplejson/simplejson
ci: [github]
os: [windows, apple, linux]
- name: Implicit
gh: benfred/implicit
ci: [github]
os: [windows, apple, linux]
notes: Includes GPU support for linux wheels
- name: power-grid-model
gh: alliander-opensource/power-grid-model
ci: [github]
os: [windows, apple, linux]
notes: Python/C++ library for distribution power system analysis
- name: Python-WebRTC
gh: MarshalX/python-webrtc
ci: [github]
os: [windows, apple, linux]
+487
View File
@@ -0,0 +1,487 @@
<div id="flow-diagram">
<div class="diagram-grid" v-bind:style="gridStyle">
<!-- BEHIND THE GRID CONTENT -->
<!-- line for each platform -->
<div class="grid-line" style="grid-row-start: 3"></div>
<div class="grid-line" style="grid-row-start: 4"></div>
<div class="grid-line" style="grid-row-start: 5"></div>
<!-- the docker container outline -->
<div class="grid-outline docker">
<div class="outline">
Manylinux Docker container
</div>
</div>
<!-- the venv outlines -->
<div class="grid-outline testVenv" style="grid-row-start: 3">
<div class="outline">Test virtualenv</div>
</div>
<div class="grid-outline testVenv" style="grid-row-start: 4"><div class="outline"></div></div>
<div class="grid-outline testVenv" style="grid-row-start: 5"><div class="outline"></div></div>
<!-- THE GRID CONTENT -->
<!-- the row labels -->
<div class="grid-row-label" style="grid-row-start: 3">Linux</div>
<div class="grid-row-label" style="grid-row-start: 4">macOS</div>
<div class="grid-row-label" style="grid-row-start: 5">Windows</div>
<!-- the column labels -->
<div class="grid-column-label"
style="grid-row: 1 / span 1; grid-column: 5 / -3">
<div class="label">For each version of Python</div>
</div>
<div class="grid-column-label"
style="grid-row: 2 / span 1;
grid-column: 8 / -3;
margin-bottom: 0.5em;">
<div class="label">If tests are configured</div>
</div>
<!-- the steps -->
<div class="step" v-for="(step, sIndex) in diagram.steps">
<component v-for="action in step"
class="action"
v-bind:is="action.href ? 'a' : 'div'"
v-bind:href="action.href">
<div class="dots" v-if="action.style == 'dot'">
<div class="dot"
v-info="action"
v-for="(platform, pIndex) in platforms"
v-if="action.platforms.includes(platform)"
v-bind:style="{gridRowStart: `${pIndex+3}`,
gridColumnStart: `${sIndex+2}`}">
<div class="dot-graphic"></div>
</div>
</div>
<div class="block-container" v-if="action.style == 'block'">
<div class="block"
v-info="action"
v-bind:style="{...blockStyle(action),
gridColumnStart: `${sIndex+2}`}">
{{action.label}}
</div>
</div>
</a>
</div>
</div>
</div>
<noscript>
<img src="data/how-it-works.png" alt="Diagram showing the steps for each platform">
<p><strong>Enable JavaScript for an interactive version of this diagram.</strong></p>
</noscript>
<script type="module" async>
import Vue from 'https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.esm.browser.js'
import 'https://unpkg.com/@popperjs/core@2/dist/umd/popper.min.js'
import 'https://unpkg.com/tippy.js@6/dist/tippy-bundle.umd.js'
const diagram = {
steps: [
[
{
label: 'copy project into docker',
platforms: ['linux'],
style: 'block',
width: 2,
},
],
[], // empty column so that the manylinux outline intersects the previous column in the middle.
[
{
href: 'options/#before-all',
platforms: ['linux', 'macos', 'windows'],
style: 'dot',
tooltip: {
title: 'CIBW_BEFORE_ALL',
tag: 'Optional step',
description: 'Execute a shell command on the build system before any wheels are built.'
},
},
],
[
{
label: 'Install Python',
platforms: ['macos', 'windows'],
style: 'block',
tooltip: {
description: 'Install the version of Python required to build this wheel.'
},
},
],
[
{
href: 'options/#before-build',
platforms: ['linux', 'macos', 'windows'],
style: 'dot',
tooltip: {
title: 'CIBW_BEFORE_BUILD',
tag: 'Optional step',
description: "Execute a shell command preparing each wheel's build.",
},
},
],
[
{
label: 'Build wheel',
href: 'options/#build-frontend',
platforms: ['linux', 'macos', 'windows'],
style: 'block',
tooltip: {
title: 'CIBW_BUILD_FRONTEND',
tag: 'Customisable step',
description: 'Build the wheel according to your package configuration, using the frontend of your choice - pip or build.'
},
},
],
[
{
label: 'Repair using auditwheel',
href: 'options/#repair-wheel-command',
platforms: ['linux'],
style: 'block',
tooltip: {
title: 'CIBW_REPAIR_WHEEL_COMMAND',
tag: 'Customisable step',
description: 'Bundle shared libraries and ensure manylinux compliance by running auditwheel on each built wheel.'
},
},
{
label: 'Repair using delocate',
href: 'options/#repair-wheel-command',
platforms: ['macos'],
style: 'block',
tooltip: {
title: 'CIBW_REPAIR_WHEEL_COMMAND',
tag: 'Customisable step',
description: 'Bundle shared libraries by running delocate on each built wheel.'
},
},
{
env: "CIBW_REPAIR_WHEEL_COMMAND",
href: 'options/#repair-wheel-command',
label: 'repair wheel',
platforms: ['windows'],
style: 'dot',
optional: true,
tooltip: {
title: 'CIBW_REPAIR_WHEEL_COMMAND',
tag: 'Optional step',
description: 'Execute a shell command to repair each built wheel'
},
},
],
[
{
href: 'options/#before-test',
platforms: ['linux', 'macos', 'windows'],
style: 'dot',
tooltip: {
title: 'CIBW_BEFORE_TEST',
tag: 'Optional step',
description: 'Execute a shell command before testing each wheel'
},
},
],
[
{
label: 'Install wheel',
platforms: ['linux', 'macos', 'windows'],
style: 'block',
tooltip: {
description: 'Install the wheel we just built into the test virtualenv.'
},
},
],
[
{
label: 'Test wheel',
href: 'options/#test-command',
platforms: ['linux', 'macos', 'windows'],
style: 'block',
tooltip: {
title: 'CIBW_TEST_COMMAND',
tag: 'Optional step',
description: 'Execute a shell command to test each built wheel'
},
},
],
[
{
label: 'Copy wheels out of Docker',
platforms: ['linux'],
style: 'block',
width: 2,
},
],
[],
]
}
const diagramComponent = new Vue({
el: '#flow-diagram',
data() {
return {
diagram,
platforms: ['linux', 'macos', 'windows'],
}
},
methods: {
blockStyle(action) {
let start, end
if (action.platforms.includes('linux')) {
start = 3
} else if (action.platforms.includes('macos')) {
start = 4
} else if (action.platforms.includes('windows')) {
start = 5
}
if (action.platforms.includes('windows')) {
end = 6
} else if (action.platforms.includes('macos')) {
end = 5
} else if (action.platforms.includes('linux')) {
end = 4
}
return {
gridRowStart: start.toString(),
gridRowEnd: end.toString(),
gridColumnEnd: `span ${action.width || 1}`,
}
}
},
computed: {
gridStyle() {
return {
gridTemplateRows: `auto auto repeat(${this.platforms.length}, 1fr)`,
gridTemplateColumns: `repeat(${this.diagram.steps.length+1}, auto)`,
}
},
},
directives: {
info: {
inserted(el, binding) {
const action = binding.value
const {env, label, optional=false, description='', href=''} = action
const tooltip = action.tooltip
if (tooltip) {
const tippyInstance = tippy(el, {
content: `
<a class="tooltip-contents" href="${href || ''}">
<div class="tooltip-title">
${tooltip.title || ''}
</div>
<div class="tooltip-tag">
${tooltip.tag || ''}
</div>
<div class="tooltip-description">
${tooltip.description}
</div>
</a>
`,
placement: 'right-start',
allowHTML: true,
maxWidth: 'none',
appendTo: document.getElementById('flow-diagram'),
offset: [0, 10],
onShow(instance) {
const stepEl = el.closest('.action')
stepEl.classList.add('tooltip-open')
instance.setProps({
interactive: tippy.currentInput.isTouch
})
},
onHide() {
const stepEl = el.closest('.action')
stepEl.classList.remove('tooltip-open')
}
})
el.addEventListener('click', e => {
// click event should just open the tooltip on touch devices
if (tippy.currentInput.isTouch) {
e.preventDefault()
}
})
}
}
}
}
})
</script>
<style>
#flow-diagram {
background: #fcfcfc;
/* font-family: Inter; */
/* font-size: 10px; */
font-size: 0.7em;
padding-bottom: 2em;
}
.no-js #flow-diagram {
display: none
}
.diagram-grid {
display: grid;
overflow-x: auto;
}
.platform, .step, .dots, .block-container, .action {
display: contents;
}
.block, .dot {
position: relative;
margin: 2em 0.5em;
}
.block {
background-color: #eee;
/* margin: 0.5em auto; */
padding: 0.5em;
max-width: 6em;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
}
.dot {
/* margin: 0.5em; */
display: flex;
align-items: center;
justify-content: center;
}
.dot-graphic {
width: 1.3em;
height: 1.3em;
border-radius: 50%;
background: #DADADA;
}
a.action {
color: inherit;
}
.action.tooltip-open .dot-graphic {
background-color: #416EDA;
}
.action.tooltip-open .block {
background-color: #416EDA;
color: white;
}
.grid-column-label {
height: 2em;
position: relative;
display: flex;
align-items: center;
justify-content: center;
margin: 0 0.5em;
}
.grid-column-label::before {
content: "";
height: 1px;
background-color: currentColor;
position: absolute;
top: calc(50% - 0.5px);
left: 0;
right: 0;
}
.grid-column-label .label {
background: #fcfcfc;
padding: 0 2em;
position: relative;
}
.grid-row-label {
grid-column: 1 / span 1;
display: flex;
align-items: center;
justify-content: flex-end;
text-align: right;
background: #fcfcfc;
position: relative;
padding-right: 1em;
font-size: 1.1em;
}
.grid-line {
grid-column: 1 / -1;
grid-row-end: span 1;
position: relative;
}
.grid-line::after {
content: "";
height: 1px;
background-color: #979797;
position: absolute;
top: calc(50% - 1px);
left: 0;
right: 0;
}
.grid-outline {
grid-row-end: span 1;
position: relative;
color: #8f8f8f;
}
.grid-outline.docker {
grid-row: 3 / span 1;
grid-column: 3 / -2;
}
.grid-outline.testVenv {
grid-column: 8 / span 4;
}
.grid-outline .outline {
position: absolute;
border: 1px solid #e5e5e5;
padding: 1px 3px;
}
.grid-outline.docker .outline {
left: 0;
right: 0;
top: 0;
bottom: 0;
}
.grid-outline.testVenv .outline {
left: 0;
right: 0;
top: 0.5em;
bottom: 0.5em;
}
/* style the tooltip */
.tippy-box {
background: white;
box-shadow: 0 2px 6px -1px rgba(0,0,0,0.12);
border-radius: 0;
text-align: left;
font-size: 1em;
color: #1F1F1F;
border: 1px solid rgba(0, 0, 0, 0.02);
width: 14em;
min-width: min-content;
}
.tippy-box[data-placement^='top'] > .tippy-arrow::before {
border-top-color: white;
}
.tippy-box[data-placement^='bottom'] > .tippy-arrow::before {
border-bottom-color: white;
}
.tippy-box[data-placement^='left'] > .tippy-arrow::before {
border-left-color: white;
}
.tippy-box[data-placement^='right'] > .tippy-arrow::before {
border-right-color: white;
}
a.tooltip-contents {
color: inherit;
text-decoration: none;
display: block;
}
.tooltip-title {
font-weight: 600;
font-size: 1.1em;
color: #416EDA;
}
.tooltip-tag {
font-weight: 500;
text-transform: uppercase;
font-size: 0.9em;
color: #C9C9C9;
}
.tooltip-description {
margin-top: 1px;
margin-bottom: 2px;
}
</style>
+1
View File
@@ -3,6 +3,7 @@
body { body {
overflow-wrap: break-word; overflow-wrap: break-word;
overflow-x: hidden;
} }
p { p {
+26 -20
View File
@@ -103,6 +103,12 @@ Linux), and the other architectures are emulated automatically.
{% include "../examples/github-with-qemu.yml" %} {% include "../examples/github-with-qemu.yml" %}
``` ```
### Building CPython ABI3 wheels (Limited API) {: #abi3}
The CPython Limited API is a subset of the Python C Extension API that's declared to be forward-compatible, meaning you can compile wheels for one version of Python, and they'll be compatible with future versions. Wheels that use the Limited API are known as ABI3 wheels.
To create a package that builds ABI3 wheels, you'll need to configure your build backend to compile libraries correctly create wheels with the right tags. [Check this repo](https://github.com/joerick/python-abi3-package-sample) for an example of how to do this with setuptools.
### Building packages with optional C extensions ### Building packages with optional C extensions
`cibuildwheel` defines the environment variable `CIBUILDWHEEL` to the value `1` allowing projects for which the C extension is optional to make it mandatory when building wheels. `cibuildwheel` defines the environment variable `CIBUILDWHEEL` to the value `1` allowing projects for which the C extension is optional to make it mandatory when building wheels.
@@ -127,7 +133,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.4.0 uses: pypa/cibuildwheel@v2.6.1
``` ```
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.
@@ -153,7 +159,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.4.0 cibuildwheel==2.6.1
``` ```
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:
@@ -179,7 +185,7 @@ package 'sdist' will also benefit.
#### Missing build dependencies {: #cibw-options-alternatives-deps} #### Missing build dependencies {: #cibw-options-alternatives-deps}
If your build needs Python dependencies, rather than using CIBW_BEFORE_BUILD, it's best to add these to the If your build needs Python dependencies, rather than using `CIBW_BEFORE_BUILD`, it's best to add these to the
[`build-system.requires`](https://www.python.org/dev/peps/pep-0518/#build-system-table) [`build-system.requires`](https://www.python.org/dev/peps/pep-0518/#build-system-table)
section of your pyproject.toml. For example, if your project requires Cython section of your pyproject.toml. For example, if your project requires Cython
to build, your pyproject.toml might include a section like this: to build, your pyproject.toml might include a section like this:
@@ -201,35 +207,35 @@ You might need to run some other commands before building, like running a
script that performs codegen or downloading some data that's not stored in script that performs codegen or downloading some data that's not stored in
your source tree. your source tree.
Rather than using CIBW_BEFORE_ALL or CIBW_BEFORE_BUILD, you could incorporate Rather than using `CIBW_BEFORE_ALL` or `CIBW_BEFORE_BUILD`, you could incorporate
these steps into your package's build process. For example, if you're using these steps into your package's build process. For example, if you're using
setuptools, you can add steps to your package's `setup.py` using a structure setuptools, you can add steps to your package's `setup.py` using a structure
like this: like this:
```python ```python
import subprocess import subprocess
import setuptools import setuptools
import setuptools.command.build_py import setuptools.command.build_py
class BuildPyCommand(setuptools.command.build_py.build_py): class BuildPyCommand(setuptools.command.build_py.build_py):
"""Custom build command.""" """Custom build command."""
def run(self): def run(self):
# your custom build steps here # your custom build steps here
# e.g. # e.g.
# subprocess.run(['python', 'scripts/my_custom_script.py'], check=True) # subprocess.run(['python', 'scripts/my_custom_script.py'], check=True)
setuptools.command.build_py.build_py.run(self) setuptools.command.build_py.build_py.run(self)
setuptools.setup( setuptools.setup(
cmdclass={ cmdclass={
'build_py': BuildPyCommand, 'build_py': BuildPyCommand,
}, },
# Usual setup() args. # Usual setup() args.
# ... # ...
) )
``` ```
#### Compiler flags #### Compiler flags
@@ -309,7 +315,7 @@ See [#816](https://github.com/pypa/cibuildwheel/issues/816), thanks to @phoeriou
Visual Studio and MSVC link the compiled binary wheels to the Microsoft Visual C++ Runtime. Normally, these are included with Python, but when compiling with a newer version of Visual Studio, it is possible users will run into problems on systems that do not have these runtime libraries installed. The solution is to ask users to download the corresponding Visual C++ Redistributable from the [Microsoft website](https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads) and install it. Since a Python installation normally includes these VC++ Redistributable files for [the version of the MSVC compiler used to compile Python](https://wiki.python.org/moin/WindowsCompilers), this is typically only a problem when compiling a Python C extension with a newer compiler. Visual Studio and MSVC link the compiled binary wheels to the Microsoft Visual C++ Runtime. Normally, these are included with Python, but when compiling with a newer version of Visual Studio, it is possible users will run into problems on systems that do not have these runtime libraries installed. The solution is to ask users to download the corresponding Visual C++ Redistributable from the [Microsoft website](https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads) and install it. Since a Python installation normally includes these VC++ Redistributable files for [the version of the MSVC compiler used to compile Python](https://wiki.python.org/moin/WindowsCompilers), this is typically only a problem when compiling a Python C extension with a newer compiler.
Additionally, Visual Studio 2019 started linking to an even newer DLL, `VCRUNTIME140_1.dll`, besides the `VCRUNTIME140.dll` that is included with recent Python versions (starting from Python 3.5; see [here](https://wiki.python.org/moin/WindowsCompilers) for more details on the corresponding Visual Studio & MSVC versions used to compile the different Python versions). To avoid this extra dependency on `VCRUNTIME140_1.dll`, the [`/d2FH4-` flag](https://devblogs.microsoft.com/cppblog/making-cpp-exception-handling-smaller-x64/) can be added to the MSVC invocations (check out [this issue](https://github.com/pypa/cibuildwheel/issues/423) for details and references). Additionally, Visual Studio 2019 started linking to an even newer DLL, `VCRUNTIME140_1.dll`, besides the `VCRUNTIME140.dll` that is included with recent Python versions (starting from Python 3.5; see [here](https://wiki.python.org/moin/WindowsCompilers) for more details on the corresponding Visual Studio & MSVC versions used to compile the different Python versions). To avoid this extra dependency on `VCRUNTIME140_1.dll`, the [`/d2FH4-` flag](https://devblogs.microsoft.com/cppblog/making-cpp-exception-handling-smaller-x64/) can be added to the MSVC invocations (check out [this issue](https://github.com/pypa/cibuildwheel/issues/423) for details and references). CPython 3.8.3 and all versions after it have this extra DLL, so it is only needed for 3.8 and earlier.
To add the `/d2FH4-` flag to a standard `setup.py` using `setuptools`, the `extra_compile_args` option can be used: To add the `/d2FH4-` flag to a standard `setup.py` using `setuptools`, the `extra_compile_args` option can be used:
+11
View File
@@ -9,3 +9,14 @@ title: Home
%} %}
To get started, head over to the [setup guide](setup.md). To get started, head over to the [setup guide](setup.md).
How it works
------------
This diagram summarises the steps that cibuildwheel takes on each platform to build your package's wheels.
{%
include-markdown "diagram.md"
%}
This isn't exhaustive, for a full list of the things cibuildwheel can do, check the [options](options.md) page.
+11 -10
View File
@@ -202,16 +202,17 @@ When setting the options, you can use shell-style globbing syntax, as per [fnmat
<div class="build-id-table-marker"></div> <div class="build-id-table-marker"></div>
| | macOS | Windows | Linux Intel | Linux Other | | | macOS | Windows | Linux Intel | Linux Other |
|--------------|------------------------------------------------------------------------|----------------------------------|-----------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------| |--------------|------------------------------------------------------------------------|-----------------------------------------------------|-----------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Python 3.6 | cp36-macosx_x86_64 | cp36-win_amd64<br/>cp36-win32 | cp36-manylinux_x86_64<br/>cp36-manylinux_i686<br/>cp36-musllinux_x86_64<br/>cp36-musllinux_i686 | cp36-manylinux_aarch64<br/>cp36-manylinux_ppc64le<br/>cp36-manylinux_s390x<br/>cp36-musllinux_aarch64<br/>cp36-musllinux_ppc64le<br/>cp36-musllinux_s390x | | Python 3.6 | cp36-macosx_x86_64 | cp36-win_amd64<br/>cp36-win32 | cp36-manylinux_x86_64<br/>cp36-manylinux_i686<br/>cp36-musllinux_x86_64<br/>cp36-musllinux_i686 | cp36-manylinux_aarch64<br/>cp36-manylinux_ppc64le<br/>cp36-manylinux_s390x<br/>cp36-musllinux_aarch64<br/>cp36-musllinux_ppc64le<br/>cp36-musllinux_s390x |
| Python 3.7 | cp37-macosx_x86_64 | cp37-win_amd64<br/>cp37-win32 | cp37-manylinux_x86_64<br/>cp37-manylinux_i686<br/>cp37-musllinux_x86_64<br/>cp37-musllinux_i686 | cp37-manylinux_aarch64<br/>cp37-manylinux_ppc64le<br/>cp37-manylinux_s390x<br/>cp37-musllinux_aarch64<br/>cp37-musllinux_ppc64le<br/>cp37-musllinux_s390x | | Python 3.7 | cp37-macosx_x86_64 | cp37-win_amd64<br/>cp37-win32 | cp37-manylinux_x86_64<br/>cp37-manylinux_i686<br/>cp37-musllinux_x86_64<br/>cp37-musllinux_i686 | cp37-manylinux_aarch64<br/>cp37-manylinux_ppc64le<br/>cp37-manylinux_s390x<br/>cp37-musllinux_aarch64<br/>cp37-musllinux_ppc64le<br/>cp37-musllinux_s390x |
| Python 3.8 | cp38-macosx_x86_64<br/>cp38-macosx_universal2<br/>cp38-macosx_arm64 | cp38-win_amd64<br/>cp38-win32 | cp38-manylinux_x86_64<br/>cp38-manylinux_i686<br/>cp38-musllinux_x86_64<br/>cp38-musllinux_i686 | cp38-manylinux_aarch64<br/>cp38-manylinux_ppc64le<br/>cp38-manylinux_s390x<br/>cp38-musllinux_aarch64<br/>cp38-musllinux_ppc64le<br/>cp38-musllinux_s390x | | Python 3.8 | cp38-macosx_x86_64<br/>cp38-macosx_universal2<br/>cp38-macosx_arm64 | cp38-win_amd64<br/>cp38-win32 | cp38-manylinux_x86_64<br/>cp38-manylinux_i686<br/>cp38-musllinux_x86_64<br/>cp38-musllinux_i686 | cp38-manylinux_aarch64<br/>cp38-manylinux_ppc64le<br/>cp38-manylinux_s390x<br/>cp38-musllinux_aarch64<br/>cp38-musllinux_ppc64le<br/>cp38-musllinux_s390x |
| Python 3.9 | cp39-macosx_x86_64<br/>cp39-macosx_universal2<br/>cp39-macosx_arm64 | cp39-win_amd64<br/>cp39-win32<br/>cp39-win_arm64 | cp39-manylinux_x86_64<br/>cp39-manylinux_i686<br/>cp39-musllinux_x86_64<br/>cp39-musllinux_i686 | cp39-manylinux_aarch64<br/>cp39-manylinux_ppc64le<br/>cp39-manylinux_s390x<br/>cp39-musllinux_aarch64<br/>cp39-musllinux_ppc64le<br/>cp39-musllinux_s390x | | Python 3.9 | cp39-macosx_x86_64<br/>cp39-macosx_universal2<br/>cp39-macosx_arm64 | cp39-win_amd64<br/>cp39-win32<br/>cp39-win_arm64 | cp39-manylinux_x86_64<br/>cp39-manylinux_i686<br/>cp39-musllinux_x86_64<br/>cp39-musllinux_i686 | cp39-manylinux_aarch64<br/>cp39-manylinux_ppc64le<br/>cp39-manylinux_s390x<br/>cp39-musllinux_aarch64<br/>cp39-musllinux_ppc64le<br/>cp39-musllinux_s390x |
| Python 3.10 | cp310-macosx_x86_64<br/>cp310-macosx_universal2<br/>cp310-macosx_arm64 | cp310-win_amd64<br/>cp310-win32<br/>cp310-win_arm64 | cp310-manylinux_x86_64<br/>cp310-manylinux_i686<br/>cp310-musllinux_x86_64<br/>cp310-musllinux_i686 | cp310-manylinux_aarch64<br/>cp310-manylinux_ppc64le<br/>cp310-manylinux_s390x<br/>cp310-musllinux_aarch64<br/>cp310-musllinux_ppc64le<br/>cp310-musllinux_s390x | | Python 3.10 | cp310-macosx_x86_64<br/>cp310-macosx_universal2<br/>cp310-macosx_arm64 | cp310-win_amd64<br/>cp310-win32<br/>cp310-win_arm64 | cp310-manylinux_x86_64<br/>cp310-manylinux_i686<br/>cp310-musllinux_x86_64<br/>cp310-musllinux_i686 | cp310-manylinux_aarch64<br/>cp310-manylinux_ppc64le<br/>cp310-manylinux_s390x<br/>cp310-musllinux_aarch64<br/>cp310-musllinux_ppc64le<br/>cp310-musllinux_s390x |
| PyPy3.7 v7.3 | pp37-macosx_x86_64 | pp37-win_amd64 | pp37-manylinux_x86_64<br/>pp37-manylinux_i686 | pp37-manylinux_aarch64 | | Python 3.11 | cp311-macosx_x86_64<br/>cp311-macosx_universal2<br/>cp311-macosx_arm64 | cp311-win_amd64<br/>cp311-win32<br/>cp311-win_arm64 | cp311-manylinux_x86_64<br/>cp311-manylinux_i686<br/>cp311-musllinux_x86_64<br/>cp311-musllinux_i686 | cp311-manylinux_aarch64<br/>cp311-manylinux_ppc64le<br/>cp311-manylinux_s390x<br/>cp311-musllinux_aarch64<br/>cp311-musllinux_ppc64le<br/>cp311-musllinux_s390x |
| PyPy3.8 v7.3 | pp38-macosx_x86_64 | pp38-win_amd64 | pp38-manylinux_x86_64<br/>pp38-manylinux_i686 | pp38-manylinux_aarch64 | | PyPy3.7 v7.3 | pp37-macosx_x86_64 | pp37-win_amd64 | pp37-manylinux_x86_64<br/>pp37-manylinux_i686 | pp37-manylinux_aarch64 |
| PyPy3.9 v7.3 | pp39-macosx_x86_64 | pp39-win_amd64 | pp39-manylinux_x86_64<br/>pp39-manylinux_i686 | pp39-manylinux_aarch64 | | PyPy3.8 v7.3 | pp38-macosx_x86_64 | pp38-win_amd64 | pp38-manylinux_x86_64<br/>pp38-manylinux_i686 | pp38-manylinux_aarch64 |
| PyPy3.9 v7.3 | pp39-macosx_x86_64 | pp39-win_amd64 | pp39-manylinux_x86_64<br/>pp39-manylinux_i686 | pp39-manylinux_aarch64 |
The list of supported and currently selected build identifiers can also be retrieved by passing the `--print-build-identifiers` flag to cibuildwheel. The list of supported and currently selected build identifiers can also be retrieved by passing the `--print-build-identifiers` flag to cibuildwheel.
The format is `python_tag-platform_tag`, with tags similar to those in [PEP 425](https://www.python.org/dev/peps/pep-0425/#details). The format is `python_tag-platform_tag`, with tags similar to those in [PEP 425](https://www.python.org/dev/peps/pep-0425/#details).
@@ -783,7 +784,7 @@ Platform-specific environment variables are also available:<br/>
### `CIBW_REPAIR_WHEEL_COMMAND` {: #repair-wheel-command} ### `CIBW_REPAIR_WHEEL_COMMAND` {: #repair-wheel-command}
> Execute a shell command to repair each (non-pure Python) built wheel > Execute a shell command to repair each built wheel
Default: Default:
+2 -2
View File
@@ -183,7 +183,7 @@ To build Linux, Mac, and Windows wheels using GitHub Actions, create a `.github/
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Build wheels - name: Build wheels
run: pipx run cibuildwheel==2.4.0 run: pipx run cibuildwheel==2.6.1
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v2
with: with:
@@ -218,7 +218,7 @@ To build Linux, Mac, and Windows wheels using GitHub Actions, create a `.github/
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
- name: Install cibuildwheel - name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.4.0 run: python -m pip install cibuildwheel==2.6.1
- name: Build wheels - name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse run: python -m cibuildwheel --output-dir wheelhouse
+149 -113
View File
@@ -9,30 +9,38 @@ title: Working examples
| Name | CI | OS | Notes | | Name | CI | OS | Notes |
|-----------------------------------|----|----|:------| |-----------------------------------|----|----|:------|
| [scikit-learn][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The machine learning library. A complex but clean config using many of cibuildwheel's features to build a large project with Cython and C++ extensions. | | [scikit-learn][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The machine learning library. A complex but clean config using many of cibuildwheel's features to build a large project with Cython and C++ extensions. |
| [NumPy][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The fundamental package for scientific computing with Python. |
| [Tornado][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. | | [Tornado][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. |
| [pytorch-fairseq][] | ![github icon][] | ![apple icon][] ![linux icon][] | Facebook AI Research Sequence-to-Sequence Toolkit written in Python. | | [pytorch-fairseq][] | ![github icon][] | ![apple icon][] ![linux icon][] | Facebook AI Research Sequence-to-Sequence Toolkit written in Python. |
| [Matplotlib][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The venerable Matplotlib, a Python library with C++ portions | | [Matplotlib][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The venerable Matplotlib, a Python library with C++ portions |
| [MyPy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | MyPyC, the compiled component of MyPy. | | [NCNN][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | ncnn is a high-performance neural network inference framework optimized for the mobile platform |
| [Kivy][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Open source UI framework written in Python, running on Windows, Linux, macOS, Android and iOS |
| [Prophet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Tool for producing high quality forecasts for time series data that has multiple seasonality with linear or non-linear growth. |
| [MyPy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | The compiled version of MyPy using MyPyC. |
| [pydantic][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Data parsing and validation using Python type hints | | [pydantic][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Data parsing and validation using Python type hints |
| [uvloop][] | ![github icon][] | ![apple icon][] ![linux icon][] | Ultra fast asyncio event loop. | | [uvloop][] | ![github icon][] | ![apple icon][] ![linux icon][] | Ultra fast asyncio event loop. |
| [MemRay][] | ![github icon][] | ![linux icon][] | Memray is a memory profiler for Python |
| [psutil][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Cross-platform lib for process and system monitoring in Python | | [psutil][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Cross-platform lib for process and system monitoring in Python |
| [vaex][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Out-of-Core hybrid Apache Arrow/NumPy DataFrame for Python, ML, visualization and exploration of big tabular data at a billion rows per second 🚀 | | [vaex][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Out-of-Core hybrid Apache Arrow/NumPy DataFrame for Python, ML, visualization and exploration of big tabular data at a billion rows per second 🚀 |
| [Google Benchmark][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A microbenchmark support library | | [Google Benchmark][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A microbenchmark support library |
| [Apache Beam][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Apache Beam is a unified programming model for Batch and Streaming | | [Apache Beam][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Apache Beam is a unified programming model for Batch and Streaming data processing. |
| [asyncpg][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A fast PostgreSQL Database Client Library for Python/asyncio. | | [asyncpg][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A fast PostgreSQL Database Client Library for Python/asyncio. |
| [scikit-image][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Image processing library. Uses cibuildwheel to build and test a project that uses Cython with platform-native code. |
| [cmake][] | ![github icon][] ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Multitagged binary builds for all supported platforms, using cibw 2 config configuration. |
| [duckdb][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | DuckDB is an in-process SQL OLAP Database Management System | | [duckdb][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | DuckDB is an in-process SQL OLAP Database Management System |
| [scikit-image][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Image processing library. Uses cibuildwheel to build and test a project that uses Cython with platform-native code. |
| [PyGame][] | ![github icon][] | ![apple icon][] ![linux icon][] | pygame (the library) is a Free and Open Source python programming language library for making multimedia applications like games built on top of the excellent SDL library. C, Python, Native, OpenGL. |
| [cmake][] | ![github icon][] ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Multitagged binary builds for all supported platforms, using cibw 2 config configuration. |
| [twisted-iocpsupport][] | ![github icon][] | ![windows icon][] | A submodule of Twisted that hooks into native C APIs using Cython. | | [twisted-iocpsupport][] | ![github icon][] | ![windows icon][] | A submodule of Twisted that hooks into native C APIs using Cython. |
| [websockets][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Library for building WebSocket servers and clients. Mostly written in Python, with a small C 'speedups' extension module. | | [websockets][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Library for building WebSocket servers and clients. Mostly written in Python, with a small C 'speedups' extension module. |
| [cvxpy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A Python-embedded modeling language for convex optimization problems. | | [cvxpy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A Python-embedded modeling language for convex optimization problems. |
| [PyOxidizer][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A modern Python application packaging and distribution tool | | [PyOxidizer][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A modern Python application packaging and distribution tool |
| [UltraJSON][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Ultra fast JSON decoder and encoder written in C with Python bindings |
| [Triton][] | ![github icon][] | ![linux icon][] | Self hosted runners | | [Triton][] | ![github icon][] | ![linux icon][] | Self hosted runners |
| [River][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | 🌊 Online machine learning in Python | | [River][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | 🌊 Online machine learning in Python |
| [OpenSpiel][] | ![github icon][] | ![apple icon][] ![linux icon][] | OpenSpiel is a collection of environments and algorithms for research in general reinforcement learning and search/planning in games. | | [OpenSpiel][] | ![github icon][] | ![apple icon][] ![linux icon][] | OpenSpiel is a collection of environments and algorithms for research in general reinforcement learning and search/planning in games. |
| [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. |
| [vispy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Main repository for Vispy | | [vispy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Main repository for Vispy |
| [Implicit][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes GPU support for linux wheels |
| [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` |
| [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 |
@@ -41,12 +49,14 @@ title: Working examples
| [PyYAML][] | ![github icon][] | ![apple icon][] | Canonical source repository for PyYAML | | [PyYAML][] | ![github icon][] | ![apple icon][] | Canonical source repository for PyYAML |
| [numexpr][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast numerical array expression evaluator for Python, NumPy, PyTables, pandas, bcolz and more | | [numexpr][] | ![github icon][] ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast numerical array expression evaluator for Python, NumPy, PyTables, pandas, bcolz and more |
| [h5py][] | ![azurepipelines icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | HDF5 for Python -- The h5py package is a Pythonic interface to the HDF5 binary data format. | | [h5py][] | ![azurepipelines icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | HDF5 for Python -- The h5py package is a Pythonic interface to the HDF5 binary data format. |
| [Wrapt][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python module for decorators, wrappers and monkey patching. |
| [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 |
| [OpenColorIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A color management framework for visual effects and animation. | | [OpenColorIO][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | A color management framework for visual effects and animation. |
| [pikepdf][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python library for reading and writing PDF, powered by qpdf |
| [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 |
| [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. |
| [pikepdf][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python library for reading and writing PDF, powered by qpdf |
| [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. |
| [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 |
| [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) |
@@ -55,8 +65,8 @@ title: Working examples
| [Parselmouth][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python interface to the Praat software package, using pybind11, C++17 and CMake, with the core Praat static library built only once and shared between wheels. | | [Parselmouth][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python interface to the Praat software package, using pybind11, C++17 and CMake, with the core Praat static library built only once and shared between wheels. |
| [AutoPy][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes a Windows Travis build. | | [AutoPy][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes a Windows Travis build. |
| [H3-py][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Python bindings for H3, a hierarchical hexagonal geospatial indexing system | | [H3-py][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Python bindings for H3, a hierarchical hexagonal geospatial indexing system |
| [markupsafe][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Safely add untrusted strings to HTML/XML markup. |
| [Rtree][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Rtree: spatial index for Python GIS ¶ | | [Rtree][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Rtree: spatial index for Python GIS ¶ |
| [markupsafe][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Safely add untrusted strings to HTML/XML markup. |
| [python-rapidjson][] | ![travisci icon][] ![gitlab icon][] ![appveyor icon][] | ![windows icon][] ![linux icon][] | Python wrapper around rapidjson | | [python-rapidjson][] | ![travisci icon][] ![gitlab icon][] ![appveyor icon][] | ![windows icon][] ![linux icon][] | Python wrapper around rapidjson |
| [python-snappy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Python bindings for the snappy google library | | [python-snappy][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Python bindings for the snappy google library |
| [pybind11 cmake_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Example pybind11 module built with a CMake-based build system | | [pybind11 cmake_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Example pybind11 module built with a CMake-based build system |
@@ -64,63 +74,73 @@ title: Working examples
| [tgcalls][] | ![github icon][] | ![apple icon][] ![windows icon][] | Python `pybind11` binding to Telegram's WebRTC library with third party dependencies like `OpenSSL`, `MozJPEG`, `FFmpeg`, etc. | | [tgcalls][] | ![github icon][] | ![apple icon][] ![windows icon][] | Python `pybind11` binding to Telegram's WebRTC library with third party dependencies like `OpenSSL`, `MozJPEG`, `FFmpeg`, etc. |
| [pybind11 python_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Example pybind11 module built with a Python-based build system | | [pybind11 python_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Example pybind11 module built with a Python-based build system |
| [dd-trace-py][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Uses custom alternate arch emulation on GitHub | | [dd-trace-py][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Uses custom alternate arch emulation on GitHub |
| [cyvcf2][] | ![github icon][] | ![apple icon][] ![linux icon][] | cython + htslib == fast VCF and BCF processing |
| [sourmash][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Quickly search, compare, and analyze genomic and metagenomic data sets. | | [sourmash][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Quickly search, compare, and analyze genomic and metagenomic data sets. |
| [time-machine][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Time mocking library using only the CPython C API. | | [time-machine][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Time mocking library using only the CPython C API. |
| [abess][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A fast best-subset selection library. It uses cibuildwheel to build a large project with C++ extensions. | | [cyvcf2][] | ![github icon][] | ![apple icon][] ![linux icon][] | cython + htslib == fast VCF and BCF processing |
| [CTranslate2][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes libraries from the [Intel oneAPI toolkit](https://www.intel.com/content/www/us/en/developer/tools/oneapi/base-toolkit.html) and CUDA kernels compiled for multiple GPU architectures. | | [CTranslate2][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Includes libraries from the [Intel oneAPI toolkit](https://www.intel.com/content/www/us/en/developer/tools/oneapi/base-toolkit.html) and CUDA kernels compiled for multiple GPU architectures. |
| [abess][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A fast best-subset selection library. It uses cibuildwheel to build a large project with C++ extensions. |
| [matrixprofile][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python 3 library making time series data mining tasks, utilizing matrix profile algorithms, accessible to everyone. | | [matrixprofile][] | ![travisci icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A Python 3 library making time series data mining tasks, utilizing matrix profile algorithms, accessible to everyone. |
| [jq.py][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Python bindings for jq | | [jq.py][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | Python bindings for jq |
| [iminuit][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Jupyter-friendly Python interface for C++ MINUIT2 | | [iminuit][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Jupyter-friendly Python interface for C++ MINUIT2 |
| [Tokenizer][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast and customizable text tokenization library with BPE and SentencePiece support | | [Tokenizer][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Fast and customizable text tokenization library with BPE and SentencePiece support |
| [PyGLM][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Fast OpenGL Mathematics (GLM) for Python | | [PyGLM][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Fast OpenGL Mathematics (GLM) for Python |
| [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. |
| [bx-python][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | A library that includes Cython extensions. |
| [iDynTree][] | ![github icon][] | ![linux icon][] | Uses manylinux_2_24 | | [iDynTree][] | ![github icon][] | ![linux icon][] | Uses manylinux_2_24 |
| [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. |
| [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. |
| [etebase-py][] | ![travisci icon][] | ![linux icon][] | Python bindings to a Rust library using `setuptools-rust`, and `sccache` for improved speed. |
| [fathon][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | python package for DFA (Detrended Fluctuation Analysis) and related algorithms | | [fathon][] | ![travisci icon][] | ![apple icon][] ![linux icon][] | python package for DFA (Detrended Fluctuation Analysis) and related algorithms |
| [etebase-py][] | ![travisci icon][] | ![linux icon][] | Python bindings to a Rust library using `setuptools-rust`, and `sccache` for improved speed. |
| [Imagecodecs (fork)][] | ![azurepipelines icon][] | ![apple icon][] ![linux icon][] | Over 20 external dependencies in compiled libraries, custom docker image, `libomp`, `openblas` and `install_name_tool` for macOS. | | [Imagecodecs (fork)][] | ![azurepipelines icon][] | ![apple icon][] ![linux icon][] | Over 20 external dependencies in compiled libraries, custom docker image, `libomp`, `openblas` and `install_name_tool` for macOS. |
| [polaroid][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Full range of wheels for setuptools rust, with auto release and PyPI deploy. | | [polaroid][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Full range of wheels for setuptools rust, with auto release and PyPI deploy. |
| [numpythia][] | ![github icon][] | ![apple icon][] ![linux icon][] | The interface between PYTHIA and NumPy |
| [pyjet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The interface between FastJet and NumPy |
| [clang-format][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Scikit-build wrapper around LLVM's CMake, all platforms, generic wheels. | | [clang-format][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Scikit-build wrapper around LLVM's CMake, all platforms, generic wheels. |
| [ninja][] | ![github icon][] ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Multitagged binary builds for all supported platforms, using cibw 2 config configuration. | | [power-grid-model][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Python/C++ library for distribution power system analysis |
| [pyjet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | The interface between FastJet and NumPy |
| [numpythia][] | ![github icon][] | ![apple icon][] ![linux icon][] | The interface between PYTHIA and NumPy |
| [pybind11 scikit_build_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | An example combining scikit-build and pybind11 | | [pybind11 scikit_build_example][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | An example combining scikit-build and pybind11 |
| [GSD][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Cython and NumPy project with 64-bit wheels. |
| [pillow-heif][] | ![github icon][] | ![apple icon][] ![linux icon][] | Python CFFI binding to libheif library with third party dependencies like `libde265`, `x265`, `libaom` with test & publishing on PyPi. | | [pillow-heif][] | ![github icon][] | ![apple icon][] ![linux icon][] | Python CFFI binding to libheif library with third party dependencies like `libde265`, `x265`, `libaom` with test & publishing on PyPi. |
| [ninja][] | ![github icon][] ![travisci icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Multitagged binary builds for all supported platforms, using cibw 2 config configuration. |
| [GSD][] | ![github icon][] | ![apple icon][] ![linux icon][] ![windows icon][] | Cython and NumPy project with 64-bit wheels. |
| [pyinstrument_cext][] | ![travisci icon][] ![appveyor icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A simple C extension, without external dependencies | | [pyinstrument_cext][] | ![travisci icon][] ![appveyor icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | A simple C extension, without external dependencies |
| [xmlstarlet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Python 3.6+ CFFI bindings with true MSVC build. | | [xmlstarlet][] | ![github icon][] | ![windows icon][] ![apple icon][] ![linux icon][] | Python 3.6+ CFFI bindings with true MSVC build. |
| [CorrectionLib][] | ![github icon][] | ![apple icon][] ![linux icon][] | Structured JSON powered correction library for HEP, designed for the CMS experiment at CERN. | | [CorrectionLib][] | ![github icon][] | ![apple icon][] ![linux icon][] | Structured JSON powered correction library for HEP, designed for the CMS experiment at CERN. |
| [SiPM][] | ![github icon][] | ![apple icon][] ![linux icon][] | High performance library for SiPM detectors simulation using C++17, OpenMP and AVX2 intrinsics. | | [SiPM][] | ![github icon][] | ![apple icon][] ![linux icon][] | High performance library for SiPM detectors simulation using C++17, OpenMP and AVX2 intrinsics. |
[scikit-learn]: https://github.com/scikit-learn/scikit-learn [scikit-learn]: https://github.com/scikit-learn/scikit-learn
[NumPy]: https://github.com/numpy/numpy
[Tornado]: https://github.com/tornadoweb/tornado [Tornado]: https://github.com/tornadoweb/tornado
[pytorch-fairseq]: https://github.com/pytorch/fairseq [pytorch-fairseq]: https://github.com/pytorch/fairseq
[Matplotlib]: https://github.com/matplotlib/matplotlib [Matplotlib]: https://github.com/matplotlib/matplotlib
[NCNN]: https://github.com/Tencent/ncnn
[Kivy]: https://github.com/kivy/kivy
[Prophet]: https://github.com/facebook/prophet
[MyPy]: https://github.com/mypyc/mypy_mypyc-wheels [MyPy]: https://github.com/mypyc/mypy_mypyc-wheels
[pydantic]: https://github.com/samuelcolvin/pydantic [pydantic]: https://github.com/samuelcolvin/pydantic
[uvloop]: https://github.com/MagicStack/uvloop [uvloop]: https://github.com/MagicStack/uvloop
[MemRay]: https://github.com/bloomberg/memray
[psutil]: https://github.com/giampaolo/psutil [psutil]: https://github.com/giampaolo/psutil
[vaex]: https://github.com/vaexio/vaex [vaex]: https://github.com/vaexio/vaex
[Google Benchmark]: https://github.com/google/benchmark [Google Benchmark]: https://github.com/google/benchmark
[Apache Beam]: https://github.com/apache/beam [Apache Beam]: https://github.com/apache/beam
[asyncpg]: https://github.com/MagicStack/asyncpg [asyncpg]: https://github.com/MagicStack/asyncpg
[scikit-image]: https://github.com/scikit-image/scikit-image
[cmake]: https://github.com/scikit-build/cmake-python-distributions
[duckdb]: https://github.com/duckdb/duckdb [duckdb]: https://github.com/duckdb/duckdb
[scikit-image]: https://github.com/scikit-image/scikit-image
[PyGame]: https://github.com/pygame/pygame
[cmake]: https://github.com/scikit-build/cmake-python-distributions
[twisted-iocpsupport]: https://github.com/twisted/twisted-iocpsupport [twisted-iocpsupport]: https://github.com/twisted/twisted-iocpsupport
[websockets]: https://github.com/aaugustin/websockets [websockets]: https://github.com/aaugustin/websockets
[cvxpy]: https://github.com/cvxpy/cvxpy [cvxpy]: https://github.com/cvxpy/cvxpy
[PyOxidizer]: https://github.com/indygreg/PyOxidizer [PyOxidizer]: https://github.com/indygreg/PyOxidizer
[UltraJSON]: https://github.com/ultrajson/ultrajson
[Triton]: https://github.com/openai/triton [Triton]: https://github.com/openai/triton
[River]: https://github.com/online-ml/river [River]: https://github.com/online-ml/river
[OpenSpiel]: https://github.com/deepmind/open_spiel [OpenSpiel]: https://github.com/deepmind/open_spiel
[pyzmq]: https://github.com/zeromq/pyzmq [pyzmq]: https://github.com/zeromq/pyzmq
[aiortc]: https://github.com/aiortc/aiortc [aiortc]: https://github.com/aiortc/aiortc
[vispy]: https://github.com/vispy/vispy [vispy]: https://github.com/vispy/vispy
[Implicit]: https://github.com/benfred/implicit
[Confluent client for Kafka]: https://github.com/confluentinc/confluent-kafka-python [Confluent client for Kafka]: https://github.com/confluentinc/confluent-kafka-python
[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
@@ -129,12 +149,14 @@ title: Working examples
[PyYAML]: https://github.com/yaml/pyyaml [PyYAML]: https://github.com/yaml/pyyaml
[numexpr]: https://github.com/pydata/numexpr [numexpr]: https://github.com/pydata/numexpr
[h5py]: https://github.com/h5py/h5py [h5py]: https://github.com/h5py/h5py
[Wrapt]: https://github.com/GrahamDumpleton/wrapt
[PyAV]: https://github.com/PyAV-Org/PyAV [PyAV]: https://github.com/PyAV-Org/PyAV
[SimpleJSON]: https://github.com/simplejson/simplejson
[OpenColorIO]: https://github.com/AcademySoftwareFoundation/OpenColorIO [OpenColorIO]: https://github.com/AcademySoftwareFoundation/OpenColorIO
[pikepdf]: https://github.com/pikepdf/pikepdf
[Line Profiler]: https://github.com/pyutils/line_profiler [Line Profiler]: https://github.com/pyutils/line_profiler
[PyTables]: https://github.com/PyTables/PyTables [PyTables]: https://github.com/PyTables/PyTables
[OpenTimelineIO]: https://github.com/PixarAnimationStudios/OpenTimelineIO [OpenTimelineIO]: https://github.com/PixarAnimationStudios/OpenTimelineIO
[pikepdf]: https://github.com/pikepdf/pikepdf
[ruptures]: https://github.com/deepcharles/ruptures [ruptures]: https://github.com/deepcharles/ruptures
[aioquic]: https://github.com/aiortc/aioquic [aioquic]: https://github.com/aiortc/aioquic
[DeepForest]: https://github.com/LAMDA-NJU/Deep-Forest [DeepForest]: https://github.com/LAMDA-NJU/Deep-Forest
@@ -143,8 +165,8 @@ title: Working examples
[Parselmouth]: https://github.com/YannickJadoul/Parselmouth [Parselmouth]: https://github.com/YannickJadoul/Parselmouth
[AutoPy]: https://github.com/autopilot-rs/autopy [AutoPy]: https://github.com/autopilot-rs/autopy
[H3-py]: https://github.com/uber/h3-py [H3-py]: https://github.com/uber/h3-py
[markupsafe]: https://github.com/pallets/markupsafe
[Rtree]: https://github.com/Toblerity/rtree [Rtree]: https://github.com/Toblerity/rtree
[markupsafe]: https://github.com/pallets/markupsafe
[python-rapidjson]: https://github.com/python-rapidjson/python-rapidjson [python-rapidjson]: https://github.com/python-rapidjson/python-rapidjson
[python-snappy]: https://github.com/andrix/python-snappy [python-snappy]: https://github.com/andrix/python-snappy
[pybind11 cmake_example]: https://github.com/pybind/cmake_example [pybind11 cmake_example]: https://github.com/pybind/cmake_example
@@ -152,33 +174,35 @@ title: Working examples
[tgcalls]: https://github.com/MarshalX/tgcalls [tgcalls]: https://github.com/MarshalX/tgcalls
[pybind11 python_example]: https://github.com/pybind/python_example [pybind11 python_example]: https://github.com/pybind/python_example
[dd-trace-py]: https://github.com/DataDog/dd-trace-py [dd-trace-py]: https://github.com/DataDog/dd-trace-py
[cyvcf2]: https://github.com/brentp/cyvcf2
[sourmash]: https://github.com/dib-lab/sourmash [sourmash]: https://github.com/dib-lab/sourmash
[time-machine]: https://github.com/adamchainz/time-machine [time-machine]: https://github.com/adamchainz/time-machine
[abess]: https://github.com/abess-team/abess [cyvcf2]: https://github.com/brentp/cyvcf2
[CTranslate2]: https://github.com/OpenNMT/CTranslate2 [CTranslate2]: https://github.com/OpenNMT/CTranslate2
[abess]: https://github.com/abess-team/abess
[matrixprofile]: https://github.com/matrix-profile-foundation/matrixprofile [matrixprofile]: https://github.com/matrix-profile-foundation/matrixprofile
[jq.py]: https://github.com/mwilliamson/jq.py [jq.py]: https://github.com/mwilliamson/jq.py
[iminuit]: https://github.com/scikit-hep/iminuit [iminuit]: https://github.com/scikit-hep/iminuit
[Tokenizer]: https://github.com/OpenNMT/Tokenizer [Tokenizer]: https://github.com/OpenNMT/Tokenizer
[PyGLM]: https://github.com/Zuzu-Typ/PyGLM [PyGLM]: https://github.com/Zuzu-Typ/PyGLM
[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
[bx-python]: https://github.com/bxlab/bx-python
[iDynTree]: https://github.com/robotology/idyntree [iDynTree]: https://github.com/robotology/idyntree
[TgCrypto]: https://github.com/pyrogram/tgcrypto [TgCrypto]: https://github.com/pyrogram/tgcrypto
[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
[etebase-py]: https://github.com/etesync/etebase-py
[fathon]: https://github.com/stfbnc/fathon [fathon]: https://github.com/stfbnc/fathon
[etebase-py]: https://github.com/etesync/etebase-py
[Imagecodecs (fork)]: https://github.com/czaki/imagecodecs_build [Imagecodecs (fork)]: https://github.com/czaki/imagecodecs_build
[polaroid]: https://github.com/daggy1234/polaroid [polaroid]: https://github.com/daggy1234/polaroid
[numpythia]: https://github.com/scikit-hep/numpythia
[pyjet]: https://github.com/scikit-hep/pyjet
[clang-format]: https://github.com/ssciwr/clang-format-wheel [clang-format]: https://github.com/ssciwr/clang-format-wheel
[ninja]: https://github.com/scikit-build/ninja-python-distributions [power-grid-model]: https://github.com/alliander-opensource/power-grid-model
[pyjet]: https://github.com/scikit-hep/pyjet
[numpythia]: https://github.com/scikit-hep/numpythia
[pybind11 scikit_build_example]: https://github.com/pybind/scikit_build_example [pybind11 scikit_build_example]: https://github.com/pybind/scikit_build_example
[GSD]: https://github.com/glotzerlab/gsd
[pillow-heif]: https://github.com/bigcat88/pillow_heif [pillow-heif]: https://github.com/bigcat88/pillow_heif
[ninja]: https://github.com/scikit-build/ninja-python-distributions
[GSD]: https://github.com/glotzerlab/gsd
[pyinstrument_cext]: https://github.com/joerick/pyinstrument_cext [pyinstrument_cext]: https://github.com/joerick/pyinstrument_cext
[xmlstarlet]: https://github.com/dimitern/xmlstarlet [xmlstarlet]: https://github.com/dimitern/xmlstarlet
[CorrectionLib]: https://github.com/cms-nanoAOD/correctionlib [CorrectionLib]: https://github.com/cms-nanoAOD/correctionlib
@@ -194,93 +218,105 @@ 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: 49555, last pushed 0 days ago --> <!-- scikit-learn: 50318, last pushed 0 days ago -->
<!-- Tornado: 20477, last pushed 1 days ago --> <!-- NumPy: 20611, last pushed 0 days ago -->
<!-- pytorch-fairseq: 16526, last pushed 2 days ago --> <!-- Tornado: 20565, last pushed 1 days ago -->
<!-- Matplotlib: 15257, last pushed 0 days ago --> <!-- pytorch-fairseq: 17149, last pushed 0 days ago -->
<!-- MyPy: 12783, last pushed 0 days ago --> <!-- Matplotlib: 15597, last pushed 0 days ago -->
<!-- pydantic: 9538, last pushed 3 days ago --> <!-- NCNN: 14686, last pushed 0 days ago -->
<!-- uvloop: 8496, last pushed 85 days ago --> <!-- Kivy: 14676, last pushed 6 days ago -->
<!-- psutil: 8240, last pushed 3 days ago --> <!-- Prophet: 14519, last pushed 0 days ago -->
<!-- vaex: 6968, last pushed 0 days ago --> <!-- MyPy: 13207, last pushed 0 days ago -->
<!-- Google Benchmark: 6312, last pushed 0 days ago --> <!-- pydantic: 10083, last pushed 4 days ago -->
<!-- Apache Beam: 5409, last pushed 0 days ago --> <!-- uvloop: 8643, last pushed 3 days ago -->
<!-- asyncpg: 5394, last pushed 4 days ago --> <!-- MemRay: 8533, last pushed 1 days ago -->
<!-- scikit-image: 4842, last pushed 0 days ago --> <!-- psutil: 8432, last pushed 1 days ago -->
<!-- cmake: 4616, last pushed 0 days ago --> <!-- vaex: 7100, last pushed 1 days ago -->
<!-- duckdb: 4607, last pushed 0 days ago --> <!-- Google Benchmark: 6519, last pushed 4 days ago -->
<!-- twisted-iocpsupport: 4550, last pushed 0 days ago --> <!-- Apache Beam: 5557, last pushed 0 days ago -->
<!-- websockets: 3862, last pushed 0 days ago --> <!-- asyncpg: 5502, last pushed 25 days ago -->
<!-- cvxpy: 3840, last pushed 5 days ago --> <!-- duckdb: 5216, last pushed 0 days ago -->
<!-- PyOxidizer: 3571, last pushed 0 days ago --> <!-- scikit-image: 4923, last pushed 1 days ago -->
<!-- Triton: 3552, last pushed 0 days ago --> <!-- PyGame: 4848, last pushed 0 days ago -->
<!-- River: 3261, last pushed 0 days ago --> <!-- cmake: 4803, last pushed 0 days ago -->
<!-- OpenSpiel: 3129, last pushed 3 days ago --> <!-- twisted-iocpsupport: 4615, last pushed 0 days ago -->
<!-- pyzmq: 3057, last pushed 3 days ago --> <!-- websockets: 3962, last pushed 21 days ago -->
<!-- aiortc: 2857, last pushed 2 days ago --> <!-- cvxpy: 3944, last pushed 0 days ago -->
<!-- vispy: 2836, last pushed 0 days ago --> <!-- PyOxidizer: 3819, last pushed 0 days ago -->
<!-- Confluent client for Kafka: 2699, last pushed 0 days ago --> <!-- UltraJSON: 3721, last pushed 1 days ago -->
<!-- tinyobjloader: 2460, last pushed 95 days ago --> <!-- Triton: 3654, last pushed 0 days ago -->
<!-- Dependency Injector: 1986, last pushed 2 days ago --> <!-- River: 3399, last pushed 0 days ago -->
<!-- coverage.py: 1972, last pushed 3 days ago --> <!-- OpenSpiel: 3202, last pushed 0 days ago -->
<!-- PyCryptodome: 1961, last pushed 2 days ago --> <!-- pyzmq: 3094, last pushed 3 days ago -->
<!-- PyYAML: 1785, last pushed 9 days ago --> <!-- aiortc: 2937, last pushed 10 days ago -->
<!-- numexpr: 1741, last pushed 2 days ago --> <!-- vispy: 2878, last pushed 0 days ago -->
<!-- h5py: 1703, last pushed 0 days ago --> <!-- Implicit: 2798, last pushed 3 days ago -->
<!-- PyAV: 1503, last pushed 0 days ago --> <!-- Confluent client for Kafka: 2797, last pushed 2 days ago -->
<!-- OpenColorIO: 1275, last pushed 0 days ago --> <!-- tinyobjloader: 2548, last pushed 160 days ago -->
<!-- Line Profiler: 1140, last pushed 0 days ago --> <!-- Dependency Injector: 2155, last pushed 49 days ago -->
<!-- PyTables: 1113, last pushed 6 days ago --> <!-- coverage.py: 2061, last pushed 0 days ago -->
<!-- OpenTimelineIO: 1023, last pushed 0 days ago --> <!-- PyCryptodome: 2014, last pushed 0 days ago -->
<!-- pikepdf: 982, last pushed 2 days ago --> <!-- PyYAML: 1854, last pushed 25 days ago -->
<!-- ruptures: 930, last pushed 3 days ago --> <!-- numexpr: 1759, last pushed 11 days ago -->
<!-- aioquic: 893, last pushed 2 days ago --> <!-- h5py: 1740, last pushed 3 days ago -->
<!-- DeepForest: 737, last pushed 252 days ago --> <!-- Wrapt: 1685, last pushed 35 days ago -->
<!-- google neuroglancer: 725, last pushed 3 days ago --> <!-- PyAV: 1574, last pushed 17 days ago -->
<!-- Psycopg 3: 638, last pushed 0 days ago --> <!-- SimpleJSON: 1490, last pushed 44 days ago -->
<!-- Parselmouth: 634, last pushed 0 days ago --> <!-- OpenColorIO: 1316, last pushed 0 days ago -->
<!-- AutoPy: 629, last pushed 97 days ago --> <!-- pikepdf: 1255, last pushed 7 days ago -->
<!-- H3-py: 498, last pushed 2 days ago --> <!-- Line Profiler: 1232, last pushed 8 days ago -->
<!-- markupsafe: 459, last pushed 17 days ago --> <!-- PyTables: 1128, last pushed 47 days ago -->
<!-- Rtree: 456, last pushed 1 days ago --> <!-- OpenTimelineIO: 1056, last pushed 0 days ago -->
<!-- python-rapidjson: 447, last pushed 23 days ago --> <!-- ruptures: 969, last pushed 19 days ago -->
<!-- python-snappy: 426, last pushed 15 days ago --> <!-- aioquic: 941, last pushed 27 days ago -->
<!-- pybind11 cmake_example: 380, last pushed 2 days ago --> <!-- DeepForest: 762, last pushed 22 days ago -->
<!-- KDEpy: 356, last pushed 50 days ago --> <!-- google neuroglancer: 736, last pushed 6 days ago -->
<!-- tgcalls: 346, last pushed 83 days ago --> <!-- Psycopg 3: 690, last pushed 0 days ago -->
<!-- pybind11 python_example: 312, last pushed 81 days ago --> <!-- Parselmouth: 661, last pushed 62 days ago -->
<!-- dd-trace-py: 300, last pushed 0 days ago --> <!-- AutoPy: 648, last pushed 162 days ago -->
<!-- cyvcf2: 294, last pushed 17 days ago --> <!-- H3-py: 532, last pushed 0 days ago -->
<!-- sourmash: 281, last pushed 0 days ago --> <!-- Rtree: 480, last pushed 47 days ago -->
<!-- time-machine: 274, last pushed 3 days ago --> <!-- markupsafe: 473, last pushed 4 days ago -->
<!-- abess: 258, last pushed 6 days ago --> <!-- python-rapidjson: 454, last pushed 11 days ago -->
<!-- CTranslate2: 254, last pushed 0 days ago --> <!-- python-snappy: 437, last pushed 81 days ago -->
<!-- matrixprofile: 250, last pushed 279 days ago --> <!-- pybind11 cmake_example: 403, last pushed 2 days ago -->
<!-- jq.py: 206, last pushed 54 days ago --> <!-- KDEpy: 374, last pushed 115 days ago -->
<!-- iminuit: 197, last pushed 2 days ago --> <!-- tgcalls: 359, last pushed 1 days ago -->
<!-- Tokenizer: 169, last pushed 25 days ago --> <!-- pybind11 python_example: 328, last pushed 2 days ago -->
<!-- PyGLM: 133, last pushed 3 days ago --> <!-- dd-trace-py: 325, last pushed 0 days ago -->
<!-- bx-python: 113, last pushed 86 days ago --> <!-- sourmash: 306, last pushed 4 days ago -->
<!-- boost-histogram: 107, last pushed 1 days ago --> <!-- time-machine: 303, last pushed 1 days ago -->
<!-- iDynTree: 98, last pushed 4 days ago --> <!-- cyvcf2: 298, last pushed 16 days ago -->
<!-- TgCrypto: 94, last pushed 28 days ago --> <!-- CTranslate2: 296, last pushed 2 days ago -->
<!-- pybase64: 82, last pushed 2 days ago --> <!-- abess: 266, last pushed 5 days ago -->
<!-- Arbor: 70, last pushed 0 days ago --> <!-- matrixprofile: 264, last pushed 345 days ago -->
<!-- etebase-py: 56, last pushed 95 days ago --> <!-- jq.py: 216, last pushed 119 days ago -->
<!-- fathon: 43, last pushed 134 days ago --> <!-- iminuit: 206, last pushed 2 days ago -->
<!-- Imagecodecs (fork): 41, last pushed 32 days ago --> <!-- Tokenizer: 183, last pushed 90 days ago -->
<!-- polaroid: 35, last pushed 110 days ago --> <!-- PyGLM: 142, last pushed 69 days ago -->
<!-- numpythia: 33, last pushed 34 days ago --> <!-- boost-histogram: 114, last pushed 6 days ago -->
<!-- pyjet: 32, last pushed 34 days ago --> <!-- bx-python: 113, last pushed 151 days ago -->
<!-- clang-format: 32, last pushed 38 days ago --> <!-- iDynTree: 105, last pushed 4 days ago -->
<!-- ninja: 23, last pushed 10 days ago --> <!-- TgCrypto: 104, last pushed 93 days ago -->
<!-- pybind11 scikit_build_example: 21, last pushed 51 days ago --> <!-- Python-WebRTC: 89, last pushed 87 days ago -->
<!-- GSD: 19, last pushed 87 days ago --> <!-- pybase64: 84, last pushed 0 days ago -->
<!-- pillow-heif: 16, last pushed 0 days ago --> <!-- Arbor: 72, last pushed 2 days ago -->
<!-- pyinstrument_cext: 10, last pushed 175 days ago --> <!-- fathon: 61, last pushed 3 days ago -->
<!-- xmlstarlet: 8, last pushed 11 days ago --> <!-- etebase-py: 57, last pushed 160 days ago -->
<!-- CorrectionLib: 8, last pushed 0 days ago --> <!-- Imagecodecs (fork): 44, last pushed 19 days ago -->
<!-- SiPM: 5, last pushed 1 days ago --> <!-- polaroid: 40, last pushed 25 days ago -->
<!-- clang-format: 37, last pushed 2 days ago -->
<!-- power-grid-model: 34, last pushed 2 days ago -->
<!-- pyjet: 33, last pushed 11 days ago -->
<!-- numpythia: 33, last pushed 10 days ago -->
<!-- pybind11 scikit_build_example: 26, last pushed 2 days ago -->
<!-- pillow-heif: 26, last pushed 3 days ago -->
<!-- ninja: 24, last pushed 0 days ago -->
<!-- GSD: 19, last pushed 4 days ago -->
<!-- pyinstrument_cext: 10, last pushed 240 days ago -->
<!-- xmlstarlet: 9, last pushed 6 days ago -->
<!-- CorrectionLib: 9, last pushed 11 days ago -->
<!-- SiPM: 6, last pushed 4 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.4.0 install: python -m pip install cibuildwheel==2.6.1
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.4.0 pip3 install cibuildwheel==2.6.1
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.4.0 python3 -m pip install cibuildwheel==2.6.1
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.4.0 pip install cibuildwheel==2.6.1
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.4.0 pip3 install --user cibuildwheel==2.6.1
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.4.0 pip3 install cibuildwheel==2.6.1
cibuildwheel --output-dir wheelhouse cibuildwheel --output-dir wheelhouse
- store_artifacts: - store_artifacts:
path: wheelhouse/ path: wheelhouse/
+1 -1
View File
@@ -10,7 +10,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.4.0 uses: pypa/cibuildwheel@v2.6.1
env: env:
CIBW_ARCHS_MACOS: x86_64 universal2 CIBW_ARCHS_MACOS: x86_64 universal2
+1 -1
View File
@@ -22,7 +22,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.4.0 uses: pypa/cibuildwheel@v2.6.1
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v2
with: with:
+1 -1
View File
@@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.4.0 uses: pypa/cibuildwheel@v2.6.1
# to supply options, put them in 'env', like: # to supply options, put them in 'env', like:
# env: # env:
# CIBW_SOME_OPTION: value # CIBW_SOME_OPTION: value
+1 -1
View File
@@ -25,7 +25,7 @@ jobs:
platforms: all platforms: all
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.4.0 uses: pypa/cibuildwheel@v2.6.1
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.4.0 - python -m pip install cibuildwheel==2.6.1
- 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.4.0 - python3 -m pip install cibuildwheel==2.6.1
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.4.0 - python3 -m pip install cibuildwheel==2.6.1
script: script:
# build the wheels, put them into './wheelhouse' # build the wheels, put them into './wheelhouse'
+2 -2
View File
@@ -55,7 +55,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.4.0 twine install: python3 -m pip install cibuildwheel==2.6.1 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
@@ -63,7 +63,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.4.0 twine install: python3 -m pip install cibuildwheel==2.6.1 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 -1
View File
@@ -7,7 +7,7 @@ import nox
nox.options.sessions = ["lint", "pylint", "check_manifest", "tests"] nox.options.sessions = ["lint", "pylint", "check_manifest", "tests"]
PYTHON_ALL_VERSIONS = ["3.6", "3.7", "3.8", "3.9", "3.10"] PYTHON_ALL_VERSIONS = ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11"]
DIR = Path(__file__).parent.resolve() DIR = Path(__file__).parent.resolve()
+5 -5
View File
@@ -1,6 +1,6 @@
[metadata] [metadata]
name = cibuildwheel name = cibuildwheel
version = 2.4.0 version = 2.6.1
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
@@ -35,10 +35,10 @@ install_requires =
bracex bracex
certifi certifi
filelock filelock
packaging packaging>=20.9
platformdirs platformdirs
tomli
dataclasses;python_version < '3.7' dataclasses;python_version < '3.7'
tomli;python_version < '3.11'
typing-extensions>=3.10.0.0;python_version < '3.8' typing-extensions>=3.10.0.0;python_version < '3.8'
python_requires = >=3.6 python_requires = >=3.6
include_package_data = True include_package_data = True
@@ -56,8 +56,8 @@ console_scripts =
cibuildwheel = resources/* cibuildwheel = resources/*
[flake8] [flake8]
ignore = E501,W503,E741,E226,B950,E203 extend-ignore = E203,E501,B950
select = C,E,F,W,B,B9 extend-select = B,B9
application-import-names = cibuildwheel application-import-names = cibuildwheel
exclude = exclude =
cibuildwheel/resources/, cibuildwheel/resources/,
+1
View File
@@ -13,6 +13,7 @@ extras = {
"pytest>=6", "pytest>=6",
"pytest-timeout", "pytest-timeout",
"pytest-xdist", "pytest-xdist",
"build",
], ],
"bin": [ "bin": [
"click", "click",
+16
View File
@@ -59,3 +59,19 @@ def test_build_identifiers(tmp_path):
assert len(expected_wheels) == len( assert len(expected_wheels) == len(
build_identifiers build_identifiers
), f"{expected_wheels} vs {build_identifiers}" ), f"{expected_wheels} vs {build_identifiers}"
def test_allow_empty(tmp_path):
project_dir = tmp_path / "project"
basic_project.generate(project_dir)
# Sanity check - --allow-empty should cause a no-op build to complete
# without error
actual_wheels = utils.cibuildwheel_run(
project_dir,
add_env={"CIBW_BUILD": "BUILD_NOTHING_AT_ALL"},
add_args=["--allow-empty"],
)
# check that nothing was built
assert len(actual_wheels) == 0
+173
View File
@@ -0,0 +1,173 @@
import os
import subprocess
import sys
import textwrap
from pathlib import Path
from tempfile import TemporaryDirectory
from test.test_projects.base import TestProject
from . import test_projects, utils
# utilities
def make_sdist(project: TestProject, working_dir: Path) -> Path:
project_dir = working_dir / "project"
project_dir.mkdir(parents=True, exist_ok=True)
project.generate(project_dir)
sdist_dir = working_dir / "sdist"
subprocess.run(
[sys.executable, "-m", "build", "--sdist", "--outdir", str(sdist_dir), str(project_dir)],
check=True,
)
return next(sdist_dir.glob("*.tar.gz"))
def cibuildwheel_from_sdist_run(sdist_path, add_env=None, config_file=None):
env = os.environ.copy()
if add_env:
env.update(add_env)
with TemporaryDirectory() as tmp_output_dir:
subprocess.run(
[
sys.executable,
"-m",
"cibuildwheel",
*(["--config-file", config_file] if config_file else []),
"--output-dir",
str(tmp_output_dir),
str(sdist_path),
],
env=env,
check=True,
)
return os.listdir(tmp_output_dir)
# tests
def test_simple(tmp_path):
basic_project = test_projects.new_c_project()
# make an sdist of the project
sdist_dir = tmp_path / "sdist"
sdist_dir.mkdir()
sdist_path = make_sdist(basic_project, sdist_dir)
# build the wheels from sdist
actual_wheels = cibuildwheel_from_sdist_run(
sdist_path,
add_env={"CIBW_BUILD": "cp39-*"},
)
# check that the expected wheels are produced
expected_wheels = [w for w in utils.expected_wheels("spam", "0.1.0") if "cp39" in w]
assert set(actual_wheels) == set(expected_wheels)
def test_external_config_file_argument(tmp_path, capfd):
basic_project = test_projects.new_c_project()
# make an sdist of the project
sdist_dir = tmp_path / "sdist"
sdist_dir.mkdir()
sdist_path = make_sdist(basic_project, sdist_dir)
# add a config file
config_file = tmp_path / "config.toml"
config_file.write_text(
textwrap.dedent(
"""
[tool.cibuildwheel]
before-all = 'echo "test log statement from before-all"'
"""
)
)
# build the wheels from sdist
actual_wheels = cibuildwheel_from_sdist_run(
sdist_path,
add_env={"CIBW_BUILD": "cp39-*"},
config_file=str(config_file),
)
# check that the expected wheels are produced
expected_wheels = [w for w in utils.expected_wheels("spam", "0.1.0") if "cp39" in w]
assert set(actual_wheels) == set(expected_wheels)
# check that before-all was run
captured = capfd.readouterr()
assert "test log statement from before-all" in captured.out
def test_config_in_pyproject_toml(tmp_path, capfd):
# make a project with a pyproject.toml
project = test_projects.new_c_project()
project.files["pyproject.toml"] = textwrap.dedent(
"""
[tool.cibuildwheel]
before-build = 'echo "test log statement from before-build 8419"'
"""
)
# make an sdist of the project
sdist_dir = tmp_path / "sdist"
sdist_dir.mkdir()
sdist_path = make_sdist(project, sdist_dir)
# build the wheels from sdist
actual_wheels = cibuildwheel_from_sdist_run(
sdist_path,
add_env={"CIBW_BUILD": "cp39-*"},
)
# check that the expected wheels are produced
expected_wheels = [w for w in utils.expected_wheels("spam", "0.1.0") if "cp39" in w]
assert set(actual_wheels) == set(expected_wheels)
# check that before-build was run
captured = capfd.readouterr()
assert "test log statement from before-build 8419" in captured.out
def test_internal_config_file_argument(tmp_path, capfd):
# make a project with a config file inside
project = test_projects.new_c_project(
setup_cfg_add="include_package_data = True",
)
project.files["wheel_build_config.toml"] = textwrap.dedent(
"""
[tool.cibuildwheel]
before-all = 'echo "test log statement from before-all 1829"'
"""
)
project.files["MANIFEST.in"] = textwrap.dedent(
"""
include wheel_build_config.toml
"""
)
# make an sdist of the project
sdist_dir = tmp_path / "sdist"
sdist_dir.mkdir()
sdist_path = make_sdist(project, sdist_dir)
# build the wheels from sdist, referencing the config file inside
actual_wheels = cibuildwheel_from_sdist_run(
sdist_path,
add_env={"CIBW_BUILD": "cp39-*"},
config_file="{package}/wheel_build_config.toml",
)
# check that the expected wheels are produced
expected_wheels = [w for w in utils.expected_wheels("spam", "0.1.0") if "cp39" in w]
assert set(actual_wheels) == set(expected_wheels)
# check that before-all was run
captured = capfd.readouterr()
assert "test log statement from before-all 1829" in captured.out
+50
View File
@@ -0,0 +1,50 @@
import textwrap
from . import test_projects, utils
limited_api_project = test_projects.new_c_project(
setup_py_add=textwrap.dedent(
r"""
cmdclass = {}
extension_kwargs = {}
if sys.version_info[:2] >= (3, 8):
from wheel.bdist_wheel import bdist_wheel as _bdist_wheel
class bdist_wheel_abi3(_bdist_wheel):
def finalize_options(self):
_bdist_wheel.finalize_options(self)
self.root_is_pure = False
def get_tag(self):
python, abi, plat = _bdist_wheel.get_tag(self)
return python, "abi3", plat
cmdclass["bdist_wheel"] = bdist_wheel_abi3
extension_kwargs["define_macros"] = [("Py_LIMITED_API", "0x03080000")]
extension_kwargs["py_limited_api"] = True
"""
),
setup_py_extension_args_add="**extension_kwargs",
setup_py_setup_args_add="cmdclass=cmdclass",
)
def test(tmp_path):
project_dir = tmp_path / "project"
limited_api_project.generate(project_dir)
# build the wheels
actual_wheels = utils.cibuildwheel_run(
project_dir,
add_env={
"CIBW_SKIP": "pp* ", # PyPy does not have a Py_LIMITED_API equivalent
},
)
# check that the expected wheels are produced
expected_wheels = [
w.replace("cp38-cp38", "cp38-abi3")
for w in utils.expected_wheels("spam", "0.1.0")
if "-pp" not in w and "-cp39" not in w and "-cp310" not in w and "-cp311" not in w
]
assert set(actual_wheels) == set(expected_wheels)
+4 -4
View File
@@ -72,8 +72,8 @@ def test(manylinux_image, tmp_path):
# We don't have a manylinux1 image for PyPy & CPython 3.10 and above # We don't have a manylinux1 image for PyPy & CPython 3.10 and above
add_env["CIBW_SKIP"] = "pp* cp31*" add_env["CIBW_SKIP"] = "pp* cp31*"
if manylinux_image in {"manylinux2010"}: if manylinux_image in {"manylinux2010"}:
# We don't have a manylinux2010 image for PyPy 3.9 # We don't have a manylinux2010 image for PyPy 3.9, CPython 3.11
add_env["CIBW_SKIP"] = "pp39*" add_env["CIBW_SKIP"] = "pp39* cp311*"
actual_wheels = utils.cibuildwheel_run(project_dir, add_env=add_env) actual_wheels = utils.cibuildwheel_run(project_dir, add_env=add_env)
@@ -92,6 +92,6 @@ def test(manylinux_image, tmp_path):
# remove PyPy & CPython 3.10 and above # remove PyPy & CPython 3.10 and above
expected_wheels = [w for w in expected_wheels if "-pp" not in w and "-cp31" not in w] expected_wheels = [w for w in expected_wheels if "-pp" not in w and "-cp31" not in w]
if manylinux_image in {"manylinux2010"}: if manylinux_image in {"manylinux2010"}:
# remove PyPy 3.9 # remove PyPy 3.9 & CPython 3.11
expected_wheels = [w for w in expected_wheels if "-pp39" not in w] expected_wheels = [w for w in expected_wheels if "-pp39" not in w and "-cp311" not in w]
assert set(actual_wheels) == set(expected_wheels) assert set(actual_wheels) == set(expected_wheels)
+3
View File
@@ -54,6 +54,7 @@ setup(
'spam', 'spam',
sources=['spam.c'], sources=['spam.c'],
libraries=libraries, libraries=libraries,
{{ setup_py_extension_args_add | indent(8) }}
)], )],
{{ setup_py_setup_args_add | indent(4) }} {{ setup_py_setup_args_add | indent(4) }}
) )
@@ -73,6 +74,7 @@ def new_c_project(
spam_c_top_level_add="", spam_c_top_level_add="",
spam_c_function_add="", spam_c_function_add="",
setup_py_add="", setup_py_add="",
setup_py_extension_args_add="",
setup_py_setup_args_add="", setup_py_setup_args_add="",
setup_cfg_add="", setup_cfg_add="",
): ):
@@ -91,6 +93,7 @@ def new_c_project(
"spam_c_top_level_add": spam_c_top_level_add, "spam_c_top_level_add": spam_c_top_level_add,
"spam_c_function_add": spam_c_function_add, "spam_c_function_add": spam_c_function_add,
"setup_py_add": setup_py_add, "setup_py_add": setup_py_add,
"setup_py_extension_args_add": setup_py_extension_args_add,
"setup_py_setup_args_add": setup_py_setup_args_add, "setup_py_setup_args_add": setup_py_setup_args_add,
"setup_cfg_add": setup_cfg_add, "setup_cfg_add": setup_cfg_add,
} }
+18 -4
View File
@@ -44,7 +44,9 @@ def cibuildwheel_get_build_identifiers(project_path, env=None, *, prerelease_pyt
return cmd_output.strip().split("\n") return cmd_output.strip().split("\n")
def cibuildwheel_run(project_path, package_dir=".", env=None, add_env=None, output_dir=None): def cibuildwheel_run(
project_path, package_dir=".", env=None, add_env=None, output_dir=None, add_args=None
):
""" """
Runs cibuildwheel as a subprocess, building the project at project_path. Runs cibuildwheel as a subprocess, building the project at project_path.
@@ -57,6 +59,7 @@ def cibuildwheel_run(project_path, package_dir=".", env=None, add_env=None, outp
:param add_env: environment used to update env :param add_env: environment used to update env
:param output_dir: directory where wheels are saved. If None, a temporary :param output_dir: directory where wheels are saved. If None, a temporary
directory will be used for the duration of the command. directory will be used for the duration of the command.
:param add_args: Additional command-line arguments to pass to cibuildwheel.
:return: list of built wheels (file names). :return: list of built wheels (file names).
""" """
if env is None: if env is None:
@@ -64,6 +67,9 @@ def cibuildwheel_run(project_path, package_dir=".", env=None, add_env=None, outp
# If present in the host environment, remove the MACOSX_DEPLOYMENT_TARGET for consistency # If present in the host environment, remove the MACOSX_DEPLOYMENT_TARGET for consistency
env.pop("MACOSX_DEPLOYMENT_TARGET", None) env.pop("MACOSX_DEPLOYMENT_TARGET", None)
if add_args is None:
add_args = []
if add_env is not None: if add_env is not None:
env.update(add_env) env.update(add_env)
@@ -77,6 +83,7 @@ def cibuildwheel_run(project_path, package_dir=".", env=None, add_env=None, outp
"--output-dir", "--output-dir",
str(output_dir or tmp_output_dir), str(output_dir or tmp_output_dir),
str(package_dir), str(package_dir),
*add_args,
], ],
env=env, env=env,
cwd=project_path, cwd=project_path,
@@ -132,14 +139,21 @@ def expected_wheels(
if musllinux_versions is None: if musllinux_versions is None:
musllinux_versions = ["musllinux_1_1"] musllinux_versions = ["musllinux_1_1"]
python_abi_tags = ["cp36-cp36m", "cp37-cp37m", "cp38-cp38", "cp39-cp39", "cp310-cp310"] python_abi_tags = [
"cp36-cp36m",
"cp37-cp37m",
"cp38-cp38",
"cp39-cp39",
"cp310-cp310",
"cp311-cp311",
]
if machine_arch in ["x86_64", "AMD64", "x86", "aarch64"]: if machine_arch in ["x86_64", "AMD64", "x86", "aarch64"]:
python_abi_tags += ["pp37-pypy37_pp73", "pp38-pypy38_pp73", "pp39-pypy39_pp73"] python_abi_tags += ["pp37-pypy37_pp73", "pp38-pypy38_pp73", "pp39-pypy39_pp73"]
if platform == "macos" and machine_arch == "arm64": if platform == "macos" and machine_arch == "arm64":
# currently, arm64 macs are only supported by cp39 & cp310 # currently, arm64 macs are only supported by cp39, cp310 & cp311
python_abi_tags = ["cp39-cp39", "cp310-cp310"] python_abi_tags = ["cp39-cp39", "cp310-cp310", "cp311-cp311"]
wheels = [] wheels = []
+7 -2
View File
@@ -1,6 +1,11 @@
import sys
from typing import Dict, List from typing import Dict, List
import tomli if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from packaging.version import Version from packaging.version import Version
from cibuildwheel.extra import Printable, dump_python_configurations from cibuildwheel.extra import Printable, dump_python_configurations
@@ -12,7 +17,7 @@ def test_compare_configs():
txt = f1.read() txt = f1.read()
with open(resources_dir / "build-platforms.toml", "rb") as f2: with open(resources_dir / "build-platforms.toml", "rb") as f2:
dict_txt = tomli.load(f2) dict_txt = tomllib.load(f2)
new_txt = dump_python_configurations(dict_txt) new_txt = dump_python_configurations(dict_txt)
print(new_txt) print(new_txt)
+4 -4
View File
@@ -1,4 +1,3 @@
import pytest
from packaging.specifiers import SpecifierSet from packaging.specifiers import SpecifierSet
from cibuildwheel.util import BuildSelector from cibuildwheel.util import BuildSelector
@@ -10,6 +9,7 @@ def test_build():
assert build_selector("cp36-manylinux_x86_64") assert build_selector("cp36-manylinux_x86_64")
assert build_selector("cp37-manylinux_x86_64") assert build_selector("cp37-manylinux_x86_64")
assert build_selector("cp310-manylinux_x86_64") assert build_selector("cp310-manylinux_x86_64")
assert not build_selector("cp311-manylinux_x86_64")
assert build_selector("pp36-manylinux_x86_64") assert build_selector("pp36-manylinux_x86_64")
assert build_selector("pp37-manylinux_x86_64") assert build_selector("pp37-manylinux_x86_64")
assert build_selector("cp36-manylinux_i686") assert build_selector("cp36-manylinux_i686")
@@ -28,11 +28,11 @@ def test_build():
assert build_selector("cp36-win_amd64") assert build_selector("cp36-win_amd64")
assert build_selector("cp37-win_amd64") assert build_selector("cp37-win_amd64")
assert build_selector("cp310-win_amd64") assert build_selector("cp310-win_amd64")
assert not build_selector("cp311-win_amd64")
assert not build_selector("pp36-win_amd64") assert not build_selector("pp36-win_amd64")
assert not build_selector("pp37-win_amd64") assert not build_selector("pp37-win_amd64")
@pytest.mark.skip("this test only makes sense when we have a prerelease python to test with")
def test_build_filter_pre(): def test_build_filter_pre():
build_selector = BuildSelector( build_selector = BuildSelector(
build_config="cp3*-* *-manylinux*", build_config="cp3*-* *-manylinux*",
@@ -41,9 +41,9 @@ def test_build_filter_pre():
) )
assert build_selector("cp37-manylinux_x86_64") assert build_selector("cp37-manylinux_x86_64")
assert build_selector("cp310-manylinux_x86_64") assert build_selector("cp311-manylinux_x86_64")
assert build_selector("cp37-win_amd64") assert build_selector("cp37-win_amd64")
assert build_selector("cp310-win_amd64") assert build_selector("cp311-win_amd64")
def test_skip(): def test_skip():
+1 -1
View File
@@ -32,7 +32,7 @@ def fake_package_dir(monkeypatch):
real_path_exists = Path.exists real_path_exists = Path.exists
def mock_path_exists(path): def mock_path_exists(path):
if path == MOCK_PACKAGE_DIR / "setup.py": if str(path).endswith(str(MOCK_PACKAGE_DIR / "setup.py")):
return True return True
else: else:
return real_path_exists(path) return real_path_exists(path)
+9 -5
View File
@@ -3,7 +3,11 @@ from fnmatch import fnmatch
from pathlib import Path from pathlib import Path
import pytest import pytest
import tomli
if sys.version_info >= (3, 11):
import tomllib
else:
import tomli as tomllib
from cibuildwheel.__main__ import main from cibuildwheel.__main__ import main
from cibuildwheel.environment import ParsedEnvironment from cibuildwheel.environment import ParsedEnvironment
@@ -20,13 +24,13 @@ def test_output_dir(platform, intercepted_build_args, monkeypatch):
main() main()
assert intercepted_build_args.args[0].globals.output_dir == OUTPUT_DIR assert intercepted_build_args.args[0].globals.output_dir == OUTPUT_DIR.resolve()
def test_output_dir_default(platform, intercepted_build_args, monkeypatch): def test_output_dir_default(platform, intercepted_build_args, monkeypatch):
main() main()
assert intercepted_build_args.args[0].globals.output_dir == Path("wheelhouse") assert intercepted_build_args.args[0].globals.output_dir == Path("wheelhouse").resolve()
@pytest.mark.parametrize("also_set_environment", [False, True]) @pytest.mark.parametrize("also_set_environment", [False, True])
@@ -39,7 +43,7 @@ def test_output_dir_argument(also_set_environment, platform, intercepted_build_a
main() main()
assert intercepted_build_args.args[0].globals.output_dir == OUTPUT_DIR assert intercepted_build_args.args[0].globals.output_dir == OUTPUT_DIR.resolve()
def test_build_selector(platform, intercepted_build_args, monkeypatch, allow_empty): def test_build_selector(platform, intercepted_build_args, monkeypatch, allow_empty):
@@ -314,7 +318,7 @@ def test_defaults(platform, intercepted_build_args):
build_options: BuildOptions = intercepted_build_args.args[0].build_options(identifier=None) build_options: BuildOptions = intercepted_build_args.args[0].build_options(identifier=None)
defaults_config_path = resources_dir / "defaults.toml" defaults_config_path = resources_dir / "defaults.toml"
with defaults_config_path.open("rb") as f: with defaults_config_path.open("rb") as f:
defaults_toml = tomli.load(f) defaults_toml = tomllib.load(f)
root_defaults = defaults_toml["tool"]["cibuildwheel"] root_defaults = defaults_toml["tool"]["cibuildwheel"]
platform_defaults = defaults_toml["tool"]["cibuildwheel"][platform] platform_defaults = defaults_toml["tool"]["cibuildwheel"][platform]
+2 -2
View File
@@ -60,14 +60,14 @@ def test_platform_argument(platform, intercepted_build_args, monkeypatch):
options = intercepted_build_args.args[0] options = intercepted_build_args.args[0]
assert options.globals.package_dir == MOCK_PACKAGE_DIR assert options.globals.package_dir == MOCK_PACKAGE_DIR.resolve()
def test_platform_environment(platform, intercepted_build_args, monkeypatch): def test_platform_environment(platform, intercepted_build_args, monkeypatch):
main() main()
options = intercepted_build_args.args[0] options = intercepted_build_args.args[0]
assert options.globals.package_dir == MOCK_PACKAGE_DIR assert options.globals.package_dir == MOCK_PACKAGE_DIR.resolve()
def test_archs_default(platform, intercepted_build_args, monkeypatch): def test_archs_default(platform, intercepted_build_args, monkeypatch):
+3 -3
View File
@@ -34,7 +34,7 @@ def test_options_1(tmp_path, monkeypatch):
f.write(PYPROJECT_1) f.write(PYPROJECT_1)
args = get_default_command_line_arguments() args = get_default_command_line_arguments()
args.package_dir = str(tmp_path) args.package_dir = tmp_path
monkeypatch.setattr(platform_module, "machine", lambda: "x86_64") monkeypatch.setattr(platform_module, "machine", lambda: "x86_64")
@@ -77,7 +77,7 @@ def test_passthrough(tmp_path, monkeypatch):
f.write(PYPROJECT_1) f.write(PYPROJECT_1)
args = get_default_command_line_arguments() args = get_default_command_line_arguments()
args.package_dir = str(tmp_path) args.package_dir = tmp_path
monkeypatch.setattr(platform_module, "machine", lambda: "x86_64") monkeypatch.setattr(platform_module, "machine", lambda: "x86_64")
monkeypatch.setenv("EXAMPLE_ENV", "ONE") monkeypatch.setenv("EXAMPLE_ENV", "ONE")
@@ -105,7 +105,7 @@ def test_passthrough(tmp_path, monkeypatch):
) )
def test_passthrough_evil(tmp_path, monkeypatch, env_var_value): def test_passthrough_evil(tmp_path, monkeypatch, env_var_value):
args = get_default_command_line_arguments() args = get_default_command_line_arguments()
args.package_dir = str(tmp_path) args.package_dir = tmp_path
monkeypatch.setattr(platform_module, "machine", lambda: "x86_64") monkeypatch.setattr(platform_module, "machine", lambda: "x86_64")
monkeypatch.setenv("CIBW_ENVIRONMENT_PASS_LINUX", "ENV_VAR") monkeypatch.setenv("CIBW_ENVIRONMENT_PASS_LINUX", "ENV_VAR")
+4 -2
View File
@@ -1,3 +1,5 @@
from pathlib import Path
from cibuildwheel.options import CommandLineArguments from cibuildwheel.options import CommandLineArguments
@@ -8,8 +10,8 @@ def get_default_command_line_arguments() -> CommandLineArguments:
defaults.allow_empty = False defaults.allow_empty = False
defaults.archs = None defaults.archs = None
defaults.config_file = "" defaults.config_file = ""
defaults.output_dir = None defaults.output_dir = Path("wheelhouse")
defaults.package_dir = "." defaults.package_dir = Path(".")
defaults.prerelease_pythons = False defaults.prerelease_pythons = False
defaults.print_build_identifiers = False defaults.print_build_identifiers = False