Add new PythonRequest::Any and VersionRequest::Any variants (#7517)
Follow-up to https://github.com/astral-sh/uv/pull/7514 and #7526 adding the `Any` variants again with slightly different semantics (i.e., they allow pre-releases) We'll be able to use this in https://github.com/astral-sh/uv/pull/7508 to avoid querying a bunch of alternative interpreters unnecessarily in the non-list case.
This commit is contained in:
@@ -305,7 +305,7 @@ impl ManagedPythonInstallation {
|
||||
pub fn satisfies(&self, request: &PythonRequest) -> bool {
|
||||
match request {
|
||||
PythonRequest::File(path) => self.executable() == *path,
|
||||
PythonRequest::Default => true,
|
||||
PythonRequest::Default | PythonRequest::Any => true,
|
||||
PythonRequest::Directory(path) => self.path() == *path,
|
||||
PythonRequest::ExecutableName(name) => self
|
||||
.executable()
|
||||
|
||||
Reference in New Issue
Block a user