Skip to content

Conversation

@nicholasjng
Copy link
Contributor

It is now possible to build Mac wheels on native machines in Github Actions, so ARM64 Mac wheels are now built and tested on M1 machines.

Also, the artifact up-/download was migrated to v4, which made it necessary to upload wheels to unique artifact names, and then later stitch them together again in a subsequent job.

The cross-platform Mac build injection in setup.py was removed, since it is no longer necessary.

I relanded a monkey-patching of Bazel build files, this time for MODULE.bazel. This is because rules_python does not allow running as the root user, which is the case in cibuildwheel+Linux (happens in a Docker container). Since I did not see a quick way of switching to rootless containers, and did not want to hardcode the config change (it can apparently cause cache misses and build failures), I inject the "ignore_root_user_error" flag into the MODULE.bazel file when running in cibuildwheel on Linux.


That last paragraph wrecked my day, but that's apparently a design choice by rules_python. I verified that the wheels build, see https://github.com/nicholasjng/benchmark/actions/runs/8691995492 (the failure is only because I screwed up the musllinux exclude flag, which I reverted back to how it was.)

It is now possible to build Mac wheels on native machines in Github
Actions, so ARM64 Mac wheels are now built and tested on M1 machines.

Also, the artifact up-/download was migrated to v4, which made it
necessary to upload wheels to unique artifact names, and then later
stitch them together again in a subsequent job.

The cross-platform Mac build injection in setup.py was removed,
since it is no longer necessary.

I relanded a monkey-patching of Bazel build files, this time for
MODULE.bazel. This is because `rules_python` does not allow running
as the root user, which is the case in cibuildwheel+Linux (happens
in a Docker container). Since I did not see a quick way of switching
to rootless containers, and did not want to hardcode the config change
(it can apparently cause cache misses and build failures), I inject the
"ignore_root_user_error" flag into the MODULE.bazel file when running
in cibuildwheel on Linux.
@dmah42 dmah42 merged commit bc946b9 into google:main Apr 15, 2024
@nicholasjng
Copy link
Contributor Author

Thanks!

@nicholasjng nicholasjng deleted the modernize-wheel-ci branch April 15, 2024 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants