cpython icon indicating copy to clipboard operation
cpython copied to clipboard

gh-125498: Replace ghccc with `preserve_none` in JIT builds

Open savannahostrowski opened this issue 1 year ago • 6 comments

  • Issue: gh-125498
  • Issue: gh-123714

savannahostrowski avatar Oct 15 '24 04:10 savannahostrowski

CI failures seem to be related to https://github.com/python/cpython/issues/125521

savannahostrowski avatar Oct 15 '24 22:10 savannahostrowski

Once CI passes, yes! Let's run the benchmarks. Thanks for the review!

savannahostrowski avatar Oct 16 '24 02:10 savannahostrowski

Can you merge in main to get this fix in? That way we can benchmark on Windows as well.

mdboom avatar Oct 18 '24 15:10 mdboom

@mdboom Done!

savannahostrowski avatar Oct 18 '24 19:10 savannahostrowski

So it looks like the Python version installed with brew is failing transitively...doing a bit of spelunking here.

savannahostrowski avatar Oct 22 '24 04:10 savannahostrowski

~Okay, after a bit of digging here, my cursory diagnosis around the failing x86 macOS runs is essentially this (and I am by no means a Homebrew or Ruby expert):~ ~- The default Python version of Homebrew was recently updated to 3.13 (see https://github.com/Homebrew/homebrew-core/pull/182840). As part of this PR, the formula for Python 3.13 seem to vastly differ from 3.12...and 3.12 was also updated.~ ~It seems like Homebrew is no longer handling overwriting files in the way it once did. More specifically, the combo of the setup-python step and then brew installing Python (via LLVM) is not cooperating. I did some testing here, and it looks like this issue only happens with 3.12 onward (preliminary run of https://github.com/savannahostrowski/test_repo_python_install/actions/runs/11453722971 but waiting on the fail-fast: false run for the full output).~

Update as of 10/22: I got a reply from a Homebrew maintainer: https://github.com/Homebrew/homebrew-core/issues/195288. It looks like this is a known GHA issue that has existed since at least May and started popping up recently as a result of some updates that GitHub made to runner images. The workaround is to remove the symlink to the pre-installed Python so that Homebrew Python is used instead. They may also start investigating overwriting the symlinks when in GHA context on their end because this seems to be a prevalent issue.

savannahostrowski avatar Oct 22 '24 05:10 savannahostrowski

Oooo, thanks for the review @brandtbucher. Great catches for cleaning things up a bit. Much simpler.

savannahostrowski avatar Oct 29 '24 22:10 savannahostrowski

Awesome! @mdboom, I'm landing this, so we should probably also update the benchmark runners that need it. Let me know if you want help.

Yep -- I'll do that now.

mdboom avatar Oct 30 '24 19:10 mdboom