Fix the free-threaded install-only downloads on macOS (#18609)

I'm honestly not sure what the root cause is here but I'm going to merge
to unblock `main` which is otherwise broken.
This commit is contained in:
Zanie Blue
2026-03-20 15:22:21 -05:00
committed by GitHub
parent bced7d57ea
commit 0967b5a28b
2 changed files with 32 additions and 31 deletions
+24 -24
View File
@@ -11,8 +11,8 @@
"minor": 15,
"patch": 0,
"prerelease": "a7",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "0f3e87d1c53de00fd077f34a8d97e871da6d7fe435fea78e86929fcb9f9eabbb",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-aarch64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "8713d894d56ee14e5f4ab82cf07d3915612346690ab4ea439fb1755c7d383cbe",
"variant": null,
"build": "20260320"
},
@@ -28,8 +28,8 @@
"minor": 15,
"patch": 0,
"prerelease": "a7",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "cdf7eb13f980abd1f4da5e4c23e6298f15dbf2cbb9f01d709f551131e905a4ec",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-x86_64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "f667703ddcfef04e0b6f2a7a1b95e9c8d359b91510ddda29150ec8109169aab0",
"variant": null,
"build": "20260320"
},
@@ -351,8 +351,8 @@
"minor": 15,
"patch": 0,
"prerelease": "a7",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-aarch64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "9c1c4d4d261a3ccbbc621f0da135c338de99916ade5b6a3d3eb29f2137a0fb6f",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "0f3e87d1c53de00fd077f34a8d97e871da6d7fe435fea78e86929fcb9f9eabbb",
"variant": "freethreaded",
"build": "20260320"
},
@@ -368,8 +368,8 @@
"minor": 15,
"patch": 0,
"prerelease": "a7",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-x86_64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "9738cdc6e6759e4c8cf78362cab63b113323a189a24476bbe12e0cf83a6c827a",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.15.0a7%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "cdf7eb13f980abd1f4da5e4c23e6298f15dbf2cbb9f01d709f551131e905a4ec",
"variant": "freethreaded",
"build": "20260320"
},
@@ -8817,8 +8817,8 @@
"minor": 14,
"patch": 3,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "fd78ee197384440691d4b5a6e2349e8cd687831e75637b292585c1d57c9a536f",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-aarch64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "f9b4a94d2d62ca77e08873b861b8cd989eda922ad3c3eafd2dfad57375e6ae61",
"variant": null,
"build": "20260320"
},
@@ -8834,8 +8834,8 @@
"minor": 14,
"patch": 3,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "674116e2111bbb5dad0da8c85b0d79a8e60b6be7f0decc097fbd3585b1fac4a2",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-x86_64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "cb8d27660e0575d33c6828c4f73c891a005d8cfade8941d889fd0efd0ff031dc",
"variant": null,
"build": "20260320"
},
@@ -9157,8 +9157,8 @@
"minor": 14,
"patch": 3,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-aarch64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "a0576bdce8ff1537d4a779beba089e1e8e5d359c46c804ccbd5f477011214f97",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "fd78ee197384440691d4b5a6e2349e8cd687831e75637b292585c1d57c9a536f",
"variant": "freethreaded",
"build": "20260320"
},
@@ -9174,8 +9174,8 @@
"minor": 14,
"patch": 3,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-x86_64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "73091963a8c149895ad920064178ade2f0df377be6f3a1b7411e32fcafd8df5a",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.14.3%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "674116e2111bbb5dad0da8c85b0d79a8e60b6be7f0decc097fbd3585b1fac4a2",
"variant": "freethreaded",
"build": "20260320"
},
@@ -26803,8 +26803,8 @@
"minor": 13,
"patch": 12,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "c0546f6e2cb78d74cb63211874b8533bac28d407cb0269bdf561f721d3923830",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-aarch64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "3b51d3715da5f943c39f987a27a1399a78917ecaf3c450b86d6c215aa8bd7ec7",
"variant": null,
"build": "20260320"
},
@@ -26820,8 +26820,8 @@
"minor": 13,
"patch": 12,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "b4e69d2e25c14ff994b7bc4f1f337529f652bc5a204a7663c1bdfc9886a5b06f",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-x86_64-apple-darwin-install_only_stripped.tar.gz",
"sha256": "1b9b6274f5cc621e40c8c39606729aed81554eff7da33ca573885a5eecb698e5",
"variant": null,
"build": "20260320"
},
@@ -27143,8 +27143,8 @@
"minor": 13,
"patch": 12,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-aarch64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "4d7e43aa4f5b3c5dfb3f1267545bccf1f20f76168c0b015a958dcf95e1a00e3e",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-aarch64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "c0546f6e2cb78d74cb63211874b8533bac28d407cb0269bdf561f721d3923830",
"variant": "freethreaded",
"build": "20260320"
},
@@ -27160,8 +27160,8 @@
"minor": 13,
"patch": 12,
"prerelease": "",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-x86_64-apple-darwin-freethreaded%2Bpgo%2Blto-full.tar.zst",
"sha256": "c518d522327026a899c037d9bf207ca20131679679206836fae5438d1b882a1a",
"url": "https://github.com/astral-sh/python-build-standalone/releases/download/20260320/cpython-3.13.12%2B20260320-x86_64-apple-darwin-freethreaded-install_only_stripped.tar.gz",
"sha256": "b4e69d2e25c14ff994b7bc4f1f337529f652bc5a204a7663c1bdfc9886a5b06f",
"variant": "freethreaded",
"build": "20260320"
},
+8 -7
View File
@@ -290,14 +290,15 @@ class CPythonFinder(Finder):
platform_str = artifact["platform"]
variant_str = artifact["variant"]
# On macOS, debug builds encode "-debug" as a platform suffix rather
# than a variant component (e.g. "aarch64-apple-darwin-debug"). Strip
# it and promote it to a build option to match the treatment applied
# when parsing filenames via the old filename regex.
# On macOS, some builds encode build options as platform suffixes
# rather than variant components (e.g. "aarch64-apple-darwin-debug",
# "aarch64-apple-darwin-freethreaded"). Strip them and promote to
# build options.
platform_build_options: list[str] = []
if platform_str.endswith("-debug"):
platform_str = platform_str[: -len("-debug")]
platform_build_options.append("debug")
for suffix in ("-debug", "-freethreaded"):
if platform_str.endswith(suffix):
platform_str = platform_str[: -len(suffix)]
platform_build_options.append(suffix.lstrip("-"))
flavor, variant_build_options = self._parse_variant(variant_str)
build_options = platform_build_options + variant_build_options