mirror of
https://github.com/astral-sh/uv.git
synced 2025-07-24 13:43:45 +00:00
Discover and respect .python-version
files in parent directories (#6370)
Uses #6369 for test coverage. Updates version file discovery to search up into parent directories. Also refactors Python request determination to avoid duplicating the user request / version file / workspace lookup logic in every command (this supersedes the work started in https://github.com/astral-sh/uv/pull/6372). There is a bit of remaining work here, mostly around documentation. There are some edge-cases where we don't use the refactored request utility, like `uv build` — I'm not sure how I'm going to handle that yet as it needs a separate root directory.
This commit is contained in:
parent
fb89b64acf
commit
8ef5949294
23 changed files with 807 additions and 252 deletions
|
@ -17,6 +17,7 @@ pub use crate::prefix::Prefix;
|
|||
pub use crate::python_version::PythonVersion;
|
||||
pub use crate::target::Target;
|
||||
pub use crate::version_files::{
|
||||
DiscoveryOptions as VersionFileDiscoveryOptions, FilePreference as VersionFilePreference,
|
||||
PythonVersionFile, PYTHON_VERSIONS_FILENAME, PYTHON_VERSION_FILENAME,
|
||||
};
|
||||
pub use crate::virtualenv::{Error as VirtualEnvError, PyVenvConfiguration, VirtualEnvironment};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue