Question: Intended use with venvs #10
-
Hi,
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
(just enabled discussions, and transferred the issue 🙂)
The default setting is unset. The option is activated only if the value is 1. Any other value (0, empty, 2), and the venv feature will be disabled.
Definitely something to avoid indeed.
The idea is to declare and create a few venvs with PDM, then use the same names with PDM Multirun: # Unfortunately I don't think PDM supports creating multiple venv in the project folder,
# so we have to tell it to create them elsewhere. But maybe I'm wrong.
pdm config venv.in_project false
pdm venv create -n 38 python3.8
pdm venv create -n 39 python3.9
pdm venv create -n 310 python3.10
pdm venv create -n 311 python3.11
pdm venv create -n 312 python3.12
export PDM_MULTIRUN_VERSIONS="38 39 310 311 312"
export PDM_MULTIRUN_USE_VENVS=1
That's a good question. I started using PEP 582's
If neither 3.10 or 3.12 are listed in pyenv's global setting, then these two versions are actually not exposed in your PATH, and PDM can't find them. Therefore they are skipped when running PDM Multirun. My recommendation here is to add all your Python versions installed through pyenv to its global setting:
Yep, I think you always need to create the venvs first, because when you set By the way thanks for the one-time donation ❤️ 🚀 ! |
Beta Was this translation helpful? Give feedback.
(just enabled discussions, and transferred the issue 🙂)
The default setting is unset. The option is activated only if the value is 1. Any other value (0, empty, 2), and the venv feature will be disabled.
Definitely something to avoid indeed.
The idea is to declare and create a few venvs with PDM, then use the same names with PDM Multirun: