Skip to content

Commit

Permalink
Replace --python with --try-first-with (#9413)
Browse files Browse the repository at this point in the history
If a tool like asdf provides a python that is first in the path, virtualenv does not use it even though it is the one
used to invoke poetry.  Using --try-first-with (introduced in 20.3.0) allows poetry to point to the prefered python.

See https://virtualenv.pypa.io/en/latest/changelog.html#v20-3-0-2021-01-10
fixes python-poetry#9278
  • Loading branch information
hexmode committed Aug 17, 2024
1 parent fe3641e commit 3175fb0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/poetry/utils/env/env_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,7 @@ def build_venv(
args = [
"--no-download",
"--no-periodic-update",
"--python",
"--try-first-with",
executable_str or sys.executable,
]

Expand Down

0 comments on commit 3175fb0

Please sign in to comment.