* drop EOL manylinux images
* chore: use multi-arch manylinux images as a source for image tag
Using multi-arch images directly messes with parallel tests for now.
Using them as a source for image tag ensures that all architecture specific tags are pointing to the same tag for a given manylinux / musllinux policy.
* Apply review suggestion
Co-authored-by: Joe Rickerby <joerick@mac.com>
---------
Co-authored-by: Joe Rickerby <joerick@mac.com>
2025-03-22 12:26:38 -04:00
Joe Rickerbyandpre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Write docs for inline dependency-versions
* Change the `inline` keyword to `packages` for better readability
* Implement inline package constraints
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Add schema for TOML properties
* Change the parsing of the option to parse filenames as-is
* Add a unit test for table-parsing of the option
* Remove unneeded shlex.quote on the dependency-version test
* Tidy-ups, comments, docs fixes
* Add test for empty packages option value
* Fix empty packages scenario
And, remove some optionals to reduce the problem space
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* chore: use SPEC 0 schedule for cibuildwheel
* remove support for {python} and {pip} in commands
* Remove specific Python versions from the update-dependencies job
The requirements pinning is done by uv now, so we don't need to
run the versions of Python to do the pinning anymore.
---------
Co-authored-by: Joe Rickerby <joerick@mac.com>
* Refactor error handling to use exceptions
cibuildwheel has up until now handled most errors by printing an error message to sys.stderr and calling sys.exit. Others were handled using Logger.error, depending on the context. We also had return codes, but these weren't explicitly defined anywhere.
This makes that convention more explicit and codified. Now to halt the program, the correct thing to do is to throw a cibuildwheel.errors.FatalError exception - that is caught in main() and printed before exiting. The existing behaviour was kept - if an error occurs within a build step (probably something to do with the build itself), the Logger.error() method is used. Outside of a build step (e.g. a misconfiguration), the behaviour is still to print 'cibuildwheel: <message>'
I also took the opportunity to add a debugging option `--debug-traceback` (and `CIBW_DEBUG_TRACEBACK`), which you can enable to see a full traceback on errors.
(I've deactivated the flake8-errmsg lint rule, as it was throwing loads of errors and these error messages aren't generally seen in a traceback context)
* add noqa rule
* Apply suggestions from code review
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
* Return to flake8-errmsg conformance
* Code review suggestions
* Subclass Exception rather than SystemExit
* apply error handling to new code and fix merge issues
* Apply review suggestion
* fix: merge issue
* Update cibuildwheel/errors.py
---------
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
Co-authored-by: mayeut <mayeut@users.noreply.github.com>
OCIContainer.container_engine -> OCIContainer.engine
OCIContainer.docker_image -> OCIContainer.image
Variables that refer to 'docker_images' have been renamed to
'container_images'
* Add test for defaults, fix platform detection
* Improve correctness of reader.identifier with block
* Fix options test to be multiplatform
* 'Refactored by Sourcery'
docs: write a section on overrides
tests: test docker launches
feat: add identifiers to launches
test: add test for correct build step generation
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
* feat: configuration support
* refactor: include manylinux, minor redesign
* "project global" overrides "default platform"
This allows overriding `repair-wheel-command` in the `[tool.cibuildwheel.global]` section.
* fix: add PyPy images
* refactor: remove global
* fix: support tables and arrays
* docs: add pyproject.toml config to docs
* docs: updates based on feedback
* fix: only join if sensible
* refactor: remove manylinux dict
* docs: examples headers and sections on each
* feat: support changing the config from the command line
* fix: use {package}
* tests: add a few tests and mention config one more place
* Restyle examples tabs to remove indent
* Unrelated docs improvements
* Absorb extra content into the tab
* Make the tabs smaller and to the right
* Copy edits to options
* Fix header ids
* Use fewer [tool.cibuildwheel] headers
* docs: minor additions/fixes
* feat: disallow options on some platforms
* docs: make the examples a tiny bit more tabby
* fix: enforce tables/lists are optionally separate
* Some unrelated fixes to the other tab styling
* Minor fix to tab styling
* Refactor to make code a bit more linear and immutable
* Minor docs changes
Co-authored-by: mayeut <mayeut@users.noreply.github.com>
Co-authored-by: Joe Rickerby <joerick@mac.com>
* Add CPython 3.10 support
* Fix logger displaying CPython 3.1 instead of 3.10
* Fix tests failing with CPython 3.10
* Use pytest instead of nose
* feat: --pre flag
Apply suggestions from code review
Co-authored-by: Matthieu Darbois <mayeut@users.noreply.github.com>
* fix: update Python update script to process beta versions
* refactor: prerelease-pythons
* Use `strtobool` to parse `CIBW_PRERELEASE_PYTHONS` env var
* Update python version filtering for universal2 & arm64
* Filter out CPython 3.10 and above for `test_manylinuxXXXX_only[manylinux1]` test
* Use CIBW_BUILD filtering rather than CIBW_SKIP for test_docker_images
* Use skip_patterns to filter out pre-releases
* Use `prerelease_pythons` instead of `pre`
* Reword `CIBW_PRERELEASE_PYTHONS` doc per review.
* Use `CIBW_PRERELEASE_PYTHONS: True` for usage example.
* Update `cibuildwheel --help` doc
* docs: add note on spec.filter
* Clean up the BuildSelector __repr__ by refactoring
* fix: remove platform variants for CIBW_PRERELEASE_PYTHONS
* docs: mention the flag
Co-authored-by: Henry Schreiner <henryschreineriii@gmail.com>
Co-authored-by: Joe Rickerby <joerick@mac.com>
* feat: requires-python
refactor: updating to current proposal
fix: add tests and fix a few issues
docs: Update mostly from @joerick
docs: update README from readthedocs
* refactor: pull out config file reading
* fix: always assume highest Python patch version
* refactor: try new design
* refactor: function and bump MyPy to 0.800
* fix: tighten AST to call only, add docs
* fix: address review points from @joerick