-
Notifications
You must be signed in to change notification settings - Fork 543
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
Python zip built with bootstrap_impl=script not runnable on macOS #2030
Comments
One approach might be to change the line
to
That would preserve existing behavior where |
Or we can use prefix instead |
I was poking this a bit yesterday. I can't find anything that indicates why the I'll just change the code to simply |
Macs have an older version of `mktemp`, one that doesn't support the `--suffix` arg. This caused the combination of Macs and `--build_python_zip --bootstrap_impl=script` to fail. To fix, remove the `--suffix` arg. As far as I can tell, the suffix string, "Bazel.runfiles_", is just informational, so this is fine to remove. Also adds tests to verify that a binary runs with/without zip and for the script bootstrap. Fixes #2030
🐞 bug report
Affected Rule
The issue is caused by the rule: python/private/stage1_bootstrap_template.sh
Is this a regression?
Yes, the Python zip built with bootstrap_impl=system_python works on macOS
Description
The stage 1 bootstrapper for Python zip file cannot run on macOS
🔬 Minimal Reproduction
bazel build --build_python_zip --@rules_python//python/config_settings:bootstrap_impl=script
🔥 Exception or Error
🌍 Your Environment
Operating System:
macOS Sonoma 14.5
Output of
bazel version
:7.2.0
Rules_python version:
0.33.2
Anything else relevant?
This line is triggered when running a Python zip file. However, the mktemp command on macOS doesn't have the option
--suffix
.The text was updated successfully, but these errors were encountered: