Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion lib/pythonx.ex
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,10 @@ defmodule Pythonx do
# located in `{python_home_path}/lib/pythonx.y` (Linux and macOS)
# or `{python_home_path}/Lib` (Windows).
#
# `python_executable_path` is the Python executable file.
# `python_executable_path` is the Python executable file. When using
# venv, it is preferable to point to an executable in the venv
# directory, which is relevant if additional packages are installed
# at runtime.
#
# ## Options
#
Expand Down
6 changes: 3 additions & 3 deletions lib/pythonx/uv.ex
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@ defmodule Pythonx.Uv do
python_home_path = make_windows_slashes(root_dir)

python_executable_path =
abs_executable_dir
|> Path.join("python.exe")
project_dir
|> Path.join(".venv/Scripts/python.exe")
|> make_windows_slashes()

venv_packages_path =
Expand All @@ -135,7 +135,7 @@ defmodule Pythonx.Uv do

python_home_path = root_dir

python_executable_path = Path.join(abs_executable_dir, "python")
python_executable_path = Path.join(project_dir, ".venv/bin/python")

venv_packages_path =
project_dir
Expand Down
Loading