From 05133e9c8a6f795aadcc409b8e2a761278e5ff1f Mon Sep 17 00:00:00 2001 From: Thomas Kluyver Date: Sat, 27 Jan 2024 18:45:49 +0000 Subject: [PATCH] Return Python from venv path and skip which() step --- flit/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flit/__init__.py b/flit/__init__.py index 47252839..68768d29 100644 --- a/flit/__init__.py +++ b/flit/__init__.py @@ -34,7 +34,7 @@ def find_python_executable(python: Optional[str] = None) -> str: for exe in ("bin/python", "Scripts/python.exe"): py = os.path.join(python, exe) if os.path.exists(py): - python = py + return os.path.abspath(py) if os.path.isabs(python): # sys.executable is absolute too return python # get absolute filepath of {python}