Skip to content
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

macOS fails to install dependencies: Could not symlink lib/libtcl8.6.dylib #128069

Open
vstinner opened this issue Dec 18, 2024 · 7 comments
Open
Labels
infra CI, GitHub Actions, buildbots, Dependabot, etc. OS-mac

Comments

@vstinner
Copy link
Member

vstinner commented Dec 18, 2024

The macOS CI of GitHub Action failed in the Install Homebrew dependencies step with:

Linking /usr/local/Cellar/tcl-tk@8/8.6.16... 
Error: Could not symlink lib/libtcl8.6.dylib
Target /usr/local/lib/libtcl8.6.dylib
is a symlink belonging to tcl-tk@8. You can unlink it:
  brew unlink tcl-tk@8

To force the link and overwrite all conflicting files:
  brew link --overwrite tcl-tk@8

To list all files that would be deleted:
  brew link --overwrite tcl-tk@8 --dry-run

cc @hugovk @ambv

Linked PRs

@tomasr8 tomasr8 added the infra CI, GitHub Actions, buildbots, Dependabot, etc. label Dec 18, 2024
@vstinner
Copy link
Member Author

vstinner commented Dec 18, 2024

I saw the failure on macos-13 image version 20241216.479 (2024-12-16):

2024-12-18T12:57:14.6389370Z ##[group]Runner Image
2024-12-18T12:57:14.6389940Z Image: macos-13
2024-12-18T12:57:14.6390470Z Version: 20241216.479
2024-12-18T12:57:14.6391690Z Included Software: https://github.com/actions/runner-images/blob/macos-13/20241216.479/images/macos/macos-13-Readme.md
2024-12-18T12:57:14.6393460Z Image Release: https://github.com/actions/runner-images/releases/tag/macos-13%2F20241216.479
2024-12-18T12:57:14.6394560Z ##[endgroup]

2024-12-18T12:57:14.6395090Z ##[group]Runner Image Provisioner
2024-12-18T12:57:14.6395820Z 2.0.404.1+573eac7f0cc07d6bb82d8b9bf5e1ffa69a554644
2024-12-18T12:57:14.6396560Z ##[endgroup]

@vstinner
Copy link
Member Author

vstinner commented Dec 18, 2024

I saw the failure on macos-13 image version 20241216.479

The job pass with macos-13 image version 20241211.456 (2024-12-11).

@hugovk
Copy link
Member

hugovk commented Dec 18, 2024

Yes:

Pass: https://github.com/python/cpython/actions/runs/12389079636/job/34581414776

2024-12-18T08:26:15.6290250Z Version: 20241211.456
2024-12-18T08:26:15.6291590Z Included Software: https://github.com/actions/runner-images/blob/macos-13/20241211.456/images/macos/macos-13-Readme.md
2024-12-18T08:26:15.6293490Z Image Release: https://github.com/actions/runner-images/releases/tag/macos-13%2F20241211.456
...
2024-12-18T08:26:39.4338960Z Linking /usr/local/Cellar/tcl-tk@8/8.6.15... 1753 symlinks created.
2024-12-18T08:26:39.4340050Z 

Fail: https://github.com/python/cpython/actions/runs/12389598892/job/34582962458

2024-12-18T09:00:08.6363650Z Version: 20241216.479
2024-12-18T09:00:08.6365420Z Included Software: https://github.com/actions/runner-images/blob/macos-13/20241216.479/images/macos/macos-13-Readme.md
2024-12-18T09:00:08.6368470Z Image Release: https://github.com/actions/runner-images/releases/tag/macos-13%2F20241216.479
...
2024-12-18T09:00:41.8750860Z Linking /usr/local/Cellar/tcl-tk@8/8.6.16... 
2024-12-18T09:00:41.8783970Z ##[error]Could not symlink lib/libtcl8.6.dylib
Target /usr/local/lib/libtcl8.6.dylib
is a symlink belonging to tcl-tk@8. You can unlink it:
  brew unlink tcl-tk@8

To force the link and overwrite all conflicting files:
  brew link --overwrite tcl-tk@8

@hugovk
Copy link
Member

hugovk commented Dec 18, 2024

The Tcl/Tk version changed from 8.6.15 to 8.6.16 in the GH image.

#127365 added the Homebrew tcl-tk@ pin to prevent Homebrew installing version 9.

https://formulae.brew.sh/formula/tcl-tk@8 says it's also on 8.6.16.

Perhaps we should try the --overwrite?

@hugovk
Copy link
Member

hugovk commented Dec 18, 2024

That installs and passes:

Linking /usr/local/Cellar/tcl-tk@8/8.6.15... 1753 symlinks created.

If you need to have this software first in your PATH instead consider running:
  echo 'export PATH="/usr/local/opt/tcl-tk@8/bin:$PATH"' >> /Users/runner/.bash_profile

hugovk@439a329

https://github.com/hugovk/cpython/actions/runs/12395563219/job/34601604141

@ZeroIntensity
Copy link
Member

ZeroIntensity commented Dec 19, 2024

It might be worth temporarily disabling the job while this gets figured out. Many PRs are stuck because of this.

@vstinner
Copy link
Member Author

That installs and passes: (...)
hugovk@439a329

I created a PR for this commit: #128090.

vstinner added a commit that referenced this issue Dec 19, 2024
…tHub image's version (#128090)

brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Dec 19, 2024
…ith GitHub image's version (pythonGH-128090)

brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version
(cherry picked from commit 46dc1ba)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
vstinner added a commit that referenced this issue Dec 19, 2024
…with GitHub image's version (GH-128090) (#128096)

gh-128069: brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version (GH-128090)

brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version
(cherry picked from commit 46dc1ba)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Dec 20, 2024
…ith GitHub image's version (pythonGH-128090)

brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version
(cherry picked from commit 46dc1ba)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
vstinner added a commit that referenced this issue Dec 20, 2024
…with GitHub image's version (GH-128090) (#128125)

gh-128069: brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version (GH-128090)

brew link --overwrite tcl-tk@8 to prevent conflict with GitHub image's version
(cherry picked from commit 46dc1ba)

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infra CI, GitHub Actions, buildbots, Dependabot, etc. OS-mac
Projects
None yet
Development

No branches or pull requests

4 participants