-
-
Notifications
You must be signed in to change notification settings - Fork 12.4k
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
File overwrite errors when installing Python 3.13 on MacOS #195288
Comments
This is a bug on GitHub's side: actions/runner-images#9966. They install python.org Python into the same place that Homebrew does which leads to the issues you've faced. I believe for backwards compatibility reasons, they're reluctant to change that decision now as even though the PATH is already configured correctly to not need to be installed in It's unfortunately not really fixable on our side. There's a number of possible solutions, depending on whichever suits your needs best:
At this point, the bug will eventually go away when |
@Bo98 Ah, thanks for the context and the solutions. Super helpful! It looks like |
Given how many people have run into this problem, I wonder if we should just overwrite these symlinks without erroring out in GitHub Actions (but show warning annotations so it's not missed). Thoughts, @Homebrew/maintainers? |
This makes sense to me 👍🏻 |
Based on discussion at Homebrew/homebrew-core#195288. I was initially inclined to scope this only to Python, but I think it makes sense to apply more generally. The issue is that users often have no control over what's already inside `HOMEBREW_PREFIX` when they run `brew install`. Given that, I think it makes sense to assume users want `--overwrite` unless configured otherwise with `HOMEBREW_GITHUB_ACTIONS_NO_INSTALL_OVERWRITE`.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
brew gist-logs <formula>
link ORbrew config
ANDbrew doctor
outputVerification
brew doctor
output saysYour system is ready to brew.
and am still able to reproduce my issue.brew update
and am still able to reproduce my issue.brew doctor
and that did not fix my problem.What were you trying to do (and why)?
I work on CPython and, specifically, our JIT compiler. As part of our workflow to build and test JIT-enabled builds, we install Python via
setup-python
andllvm
via Homebrew for macos builds. While LLVM has a transitive dependency on Python, we previously had no issues with this workflow.However, it seems like the default Python version of Homebrew was recently updated to 3.13 and some changes were made to the 3.12 formula (via #182840), and Homebrew may no longer be handling overwriting files as it once did. On recent runs (see this run for example), we are now seeing errors related to overwriting files related to this transitive dependency LLVM has on Python 3.13.
Although I'm running into this in a pipeline, I'd suspect that a user could run into this in their local environment if they have 3.12 installed and then try to
brew install [email protected]
...or they install a package that depends on it (for example).What happened (include all command output)?
What did you expect to happen?
To successfully install LLVM without error.
Step-by-step reproduction instructions (by running
brew
commands)https://github.com/savannahostrowski/test_repo_python_install contains a minimum reproducer. The GHA essentially just runs
setup-python
and then installs various versions of Python withbrew
. You'll notice that 3.12 and 3.13 fail.The text was updated successfully, but these errors were encountered: