mirror of
https://github.com/astral-sh/uv
synced 2026-06-21 13:47:25 +00:00
blocklist the linux cpython builds from 20250517 (#13617)
There is a runtime issue with some of these builds Here is the testing I've seen (❌ has bug, ✅ works): * uv version (pbs version) * ❌ uv 0.7.7 (pbs 20250521) * ❌ uv 0.7.6 (pbs 20250517) * ✅ uv 0.7.5 (pbs 20250409) * os * ❌ linux * ✅ windows * arch * ❌ x86_64 * ✅ aarch64 * python version * ❌ 3.12 * ❌ 3.13 * ❌ 3.14 Fixes #13610
This commit is contained in:
+278
-1142
File diff suppressed because it is too large
Load Diff
@@ -64,6 +64,11 @@ VERSIONS_FILE = SELF_DIR / "download-metadata.json"
|
||||
# The date at which the default CPython musl builds became dynamically linked
|
||||
# instead of statically.
|
||||
CPYTHON_MUSL_STATIC_RELEASE_END = 20250311
|
||||
# The date at which the linux CPython builds started to have seemingly buggy runtimes
|
||||
CPYTHON_BAD_LINUX_RUNTIME_START = 20250517
|
||||
# This alpha was introduced in the bad linux runtime, and we don't want to show it
|
||||
# only on some platforms, so hide it everywhere.
|
||||
CPYTHON_HIDDEN_ALPHA = "3.14.0a7"
|
||||
|
||||
|
||||
def batched(iterable: Iterable, n: int) -> Generator[tuple, None, None]:
|
||||
@@ -264,6 +269,14 @@ class CPythonFinder(Finder):
|
||||
and download.triple.libc == "musl"
|
||||
):
|
||||
continue
|
||||
if (
|
||||
download.release >= CPYTHON_BAD_LINUX_RUNTIME_START
|
||||
and download.triple.platform == "linux"
|
||||
and download.triple.arch.family != "aarch64"
|
||||
):
|
||||
continue
|
||||
if str(download.version) == CPYTHON_HIDDEN_ALPHA:
|
||||
continue
|
||||
logging.debug("Found %s (%s)", download.key(), download.filename)
|
||||
downloads_by_version.setdefault(download.version, []).append(
|
||||
download
|
||||
|
||||
@@ -3,8 +3,9 @@ use std::{env, path::Path, process::Command};
|
||||
use crate::common::{TestContext, uv_snapshot};
|
||||
use assert_fs::{
|
||||
assert::PathAssert,
|
||||
prelude::{FileTouch, PathChild, PathCreateDir},
|
||||
prelude::{FileTouch, FileWriteStr, PathChild, PathCreateDir},
|
||||
};
|
||||
use indoc::indoc;
|
||||
use predicates::prelude::predicate;
|
||||
use tracing::debug;
|
||||
use uv_fs::Simplified;
|
||||
@@ -286,6 +287,41 @@ fn python_install_automatic() {
|
||||
}
|
||||
}
|
||||
|
||||
/// Regression test for a bad cpython runtime
|
||||
/// <https://github.com/astral-sh/uv/issues/13610>
|
||||
#[test]
|
||||
fn regression_cpython() {
|
||||
let context: TestContext = TestContext::new_with_versions(&[])
|
||||
.with_filtered_python_keys()
|
||||
.with_filtered_exe_suffix()
|
||||
.with_filtered_python_sources()
|
||||
.with_managed_python_dirs();
|
||||
|
||||
let init = context.temp_dir.child("mre.py");
|
||||
init.write_str(indoc! { r#"
|
||||
class Foo(str): ...
|
||||
|
||||
a = []
|
||||
new_value = Foo("1")
|
||||
a += new_value
|
||||
"#
|
||||
})
|
||||
.unwrap();
|
||||
|
||||
// We should respect the Python request
|
||||
uv_snapshot!(context.filters(), context.run()
|
||||
.env_remove("VIRTUAL_ENV")
|
||||
.arg("-p").arg("3.12")
|
||||
.arg("mre.py"), @r###"
|
||||
success: true
|
||||
exit_code: 0
|
||||
----- stdout -----
|
||||
|
||||
----- stderr -----
|
||||
|
||||
"###);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn python_install_preview() {
|
||||
let context: TestContext = TestContext::new_with_versions(&[])
|
||||
@@ -1220,8 +1256,8 @@ fn python_install_314() {
|
||||
----- stdout -----
|
||||
|
||||
----- stderr -----
|
||||
Installed Python 3.14.0a7 in [TIME]
|
||||
+ cpython-3.14.0a7-[PLATFORM]
|
||||
Installed Python 3.14.0a6 in [TIME]
|
||||
+ cpython-3.14.0a6-[PLATFORM]
|
||||
");
|
||||
|
||||
// Install a specific pre-release
|
||||
@@ -1241,7 +1277,7 @@ fn python_install_314() {
|
||||
success: true
|
||||
exit_code: 0
|
||||
----- stdout -----
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a7-[PLATFORM]/[INSTALL-BIN]/python
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a6-[PLATFORM]/[INSTALL-BIN]/python
|
||||
|
||||
----- stderr -----
|
||||
");
|
||||
@@ -1251,7 +1287,7 @@ fn python_install_314() {
|
||||
success: true
|
||||
exit_code: 0
|
||||
----- stdout -----
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a7-[PLATFORM]/[INSTALL-BIN]/python
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a6-[PLATFORM]/[INSTALL-BIN]/python
|
||||
|
||||
----- stderr -----
|
||||
");
|
||||
@@ -1260,7 +1296,7 @@ fn python_install_314() {
|
||||
success: true
|
||||
exit_code: 0
|
||||
----- stdout -----
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a7-[PLATFORM]/[INSTALL-BIN]/python
|
||||
[TEMP_DIR]/managed/cpython-3.14.0a6-[PLATFORM]/[INSTALL-BIN]/python
|
||||
|
||||
----- stderr -----
|
||||
");
|
||||
|
||||
Reference in New Issue
Block a user