Can we use install libraries inside a particular directory by turning off Virtual environment? #10517
-
We have a requirement of installing the libraries and binaries inside a custom file path, but we don't want the creation of virtual environment. Can anyone help us to resolve this issue? |
Beta Was this translation helpful? Give feedback.
Answered by
finswimmer
Aug 25, 2025
Replies: 1 comment 3 replies
-
Why? This is almost always a bad idea. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
"We always did it before" is not really a useful answer ;) The question is, why you always did it before?
There is no way to tell poetry to install certain dependencies to a choosen location. What you can do, is to create a venv using python's venv module at the desired place (
python -m venv <path/to/venv>
), activate it manually (source <path/to/venv>/bin/activate
) and than runpoetry install
. Poetry will than use the activated venv to install the dependencies.