I am using Poetry in some of my python projects. It's not unusual that at some stage I want to rename the root folder of my project. When I do that and run poetry shell
poetry creates a new virtual environment. But I don't want a new virtual environment, I just want to keep using the existing virtual environment. I know I can manually activate the old one by running source {path to the old venv}/bin/activate
but then I would have to keep track of the old environment name separately and refrain from using poetry shell
.
Is there something I can do about this? It's quite time consuming to start installing the dependencies again, pointing an IDE to the new environment and deleting the old virtual env, just because you have changed the root folder name - something that can happen multiple times. This question suggests that there is no solution to the problem but would want to confirm this because to me this seems quite annoying issue.