mirror of
https://github.com/astral-sh/uv.git
synced 2025-07-17 10:15:00 +00:00
Drop Python version range enforcement from PythonVersion::from_str
(#7264)
This caused some problems earlier, as it prevented us from _listing_ Python versions <3.7 which seems weird (see https://github.com/astral-sh/uv/pull/7131#issuecomment-2334929000) I'm worried that without this the changes to installation key parsing in https://github.com/astral-sh/uv/pull/7263 would otherwise be too restrictive. I think if we want to enforce these ranges, we should do so separately from the parse step.
This commit is contained in:
parent
4f03d204df
commit
533c7e3bfd
1 changed files with 0 additions and 6 deletions
|
@ -31,12 +31,6 @@ impl FromStr for PythonVersion {
|
|||
if version.epoch() != 0 {
|
||||
return Err(format!("Python version `{s}` has a non-zero epoch"));
|
||||
}
|
||||
if version.version < Version::new([3, 7]) {
|
||||
return Err(format!("Python version `{s}` must be >= 3.7"));
|
||||
}
|
||||
if version.version >= Version::new([4, 0]) {
|
||||
return Err(format!("Python version `{s}` must be < 4.0"));
|
||||
}
|
||||
|
||||
Ok(Self(version))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue