-
Notifications
You must be signed in to change notification settings - Fork 262
feature: allow local runs on windows/macOS #974
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
15dde4a
to
583d5f7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far! I would have thought that creating a virtualenv for every build would have made the macos/windows builds much slower, but it seems that the concurrency makes up for it!
810c5a7
to
d048d8e
Compare
61380e6
to
3c6d509
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Brilliant work on this @mayeut !
Cache python installations to a user cache folder using platformdirs. The build environment is now a virtual environment to allow proper isolation. Allows to run tests in parallel.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thanks for working on this @mayeut, it's a big improvement for usability.
I also pushed some docs updates. Feel free to edit those if you like.
That looks good thanks. |
Historically, we required `--platform` when running cibuildwheel outside of CI, because cibuildwheel would attempt to globally install Python interpreters and some packages. That was fixed in #974 a couple of years ago. As a result, there's no reason to require --platform these days, the `auto` behaviour is perfectly fine for dev machines. It also makes running tests locally simpler, one can just do `pytest test/test_0_basic.py` (or `nox -s tests -- test/test_0_basic.py`) and not have to worry about setting CIBW_PLATFORM most of the time.
Specific for macOS:
The python.org installers are still installed globally, only one
{major}.{minor}
is allowed to be installed at a time.The way this is handled does not change with this PR meaning that there might be a mismatch between the installed python version and the one expected by cibuildwheel.
Given shudoers right are necessary to do the installation, in order for local runs to work, the user still has to install the relevant python versions manually.
Edit by joerick: Fixes #104