Skip to content

Fix macOS build #2918

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

Merged
merged 1 commit into from
Dec 10, 2023
Merged

Fix macOS build #2918

merged 1 commit into from
Dec 10, 2023

Conversation

amolenaar
Copy link
Member

@amolenaar amolenaar commented Dec 9, 2023

PR Type

What kind of change does this PR introduce?

  • Bug fix
  • Feature
  • Chore (refactoring, formatting, local variables, other cleanup)
  • Documentation content changes

What is the current behavior?

The macOS build fails when installing dependencies with an error:

Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink bin/2to3-3.12
Target /usr/local/bin/2to3-3.12
already exists. You may want to remove it:
  rm '/usr/local/bin/2to3-3.12'

What is the new behavior?

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

Pipx is said to be pre-installed on all runners. Although it doesn't seem to work on all.
It looks like the WIndows runner is dependent on python-launcher.

For macOS we do not need that per se. Hence I removed it and just changed the python version so it matches the old style (python3.12).

@amolenaar amolenaar marked this pull request as draft December 9, 2023 16:19
@amolenaar amolenaar changed the title Remove brew update step in install Fix macOS build Dec 9, 2023
@danyeaw
Copy link
Member

danyeaw commented Dec 9, 2023

Here is the issue for this: actions/runner-images#11545

Should we do something hacky like:

brew update
brew install ... || true
brew link --overwrite python@3.12

@amolenaar amolenaar force-pushed the fix-brew-macos branch 2 times, most recently from aec8c2c to 805ad9b Compare December 10, 2023 11:33
So it works properly and without python-launcher.
@amolenaar amolenaar marked this pull request as ready for review December 10, 2023 12:04
@amolenaar amolenaar requested a review from danyeaw December 10, 2023 12:04
Copy link
Member

@danyeaw danyeaw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, that works!

@danyeaw danyeaw added the fix A fix for a bug label Dec 10, 2023
@danyeaw danyeaw merged commit abd571d into main Dec 10, 2023
@danyeaw danyeaw deleted the fix-brew-macos branch December 10, 2023 13:53
@amolenaar
Copy link
Member Author

Yeah. It took quite some attempts, but I'm happy with the small change that's needed to make it work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix A fix for a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants