File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
crates/uv/src/commands/project Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -441,8 +441,18 @@ pub(crate) async fn run(
441
441
. connectivity ( connectivity)
442
442
. native_tls ( native_tls) ;
443
443
444
+ // (1) Explicit request from user
445
+ let python_request = if let Some ( request) = python. as_deref ( ) {
446
+ Some ( PythonRequest :: parse ( request) )
447
+ // (2) Request from `.python-version`
448
+ } else if let Some ( request) = request_from_version_file ( & CWD ) . await ? {
449
+ Some ( request)
450
+ } else {
451
+ None
452
+ } ;
453
+
444
454
let python = PythonInstallation :: find_or_download (
445
- python . as_deref ( ) . map ( PythonRequest :: parse ) ,
455
+ python_request ,
446
456
// No opt-in is required for system environments, since we are not mutating it.
447
457
EnvironmentPreference :: Any ,
448
458
python_preference,
You can’t perform that action at this time.
0 commit comments