-
Notifications
You must be signed in to change notification settings - Fork 542
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 3.10.13 does not work after uninstalling Homebrew #783
Comments
transferring to setup-python, but from what is seen, you can not uninstall brew, python3.10 is built against some dynamic shared libraries which are installed in the runner using homebrew, if you are uninstalling home-brew it leaves the deportee situation entirely to you and you should manually provide all the searchpaths |
The proper solution should be to not build against Homebrew since that would mean that any artifacts generated that contain the python library are now tied to Homebrew. The official CPython builds do not have such a dependency and keeping as close as possible to official builds should be preferred. |
This also affects standard runner on macos-14:
gives:
|
Hello @Maxwell175, Uninstalling Homebrew has resulted in the deletion of some related directories, including the one containing gettext, which is needed to install Python. The rebuilt Python package expects the gettext package at the previously provided path, but the package is located in the Cellar folder, which is the default behavior of Homebrew. This is the root cause. It might be a build process issue (incorrect set of options) or a Python core dependencies issue. The version of Python 3.10.13 that you are using was built with Homebrew present, resulting in a dependency on Homebrew-specific libraries such as libintl.8.dylib. When Homebrew is uninstalled and these libraries are no longer available, it causes Python to fail. For Python >= 3.11, the builds are directly downloaded from python.org as universal2 binaries. These binaries are pre-built and do not have dependencies on Homebrew, thus avoiding the issue of missing Homebrew-specific libraries when Homebrew is uninstalled. This change in the build process for Python >= 3.11 ensures that these versions do not rely on Homebrew and are more portable across different macOS environments. |
Description
For my use-case I need to uninstall homebrew in order to prevent dependencies on homebrew-specific versions of libraries.
After doing this, I noticed that python 3.10 fails to start with the following error:
Probably that version of CPython was built with Homebrew present which contaminated it.
Platforms affected
Runner images affected
Image version and build link
macOS 12 20231216.1
https://dev.azure.com/Nuitka/Nuitka-Watch/_build/results?buildId=38&view=logs&j=7f33e5bd-7764-5d8a-ba2e-506e078b9c3f&t=5f980cba-253f-56da-0cba-c1322a20cb47
Is it regression?
Unknown. Python 3.11 works.
Expected behavior
Python should not depend on Homebrew.
Actual behavior
Python 3.10 fails to start when Homebrew is removed.
Repro steps
The text was updated successfully, but these errors were encountered: