I have a monorepo structured like this:
myRepo/
├─ project_1/
│ ├─ .venv/
│ ├─ main.py
├─ project_2/
│ ├─ .venv/
│ ├─ main.py
├─ .gitignore
├─ README.md
- Can VS Code handle multiple python venvs in subfolders?
After some googling I managed a find one solution, but its not very elegant. I created a workspace and added the folders /project_1
and /project_2
, that worked and I can easily switch and select Python Interpreter. I also need to modify files in /root
from time to time so I added this folder as well. All this makes the Explorer folder structure bigger and more cluttered with duplicates of itself:
workspace/
├── myRepo/
│ ├── project_1/
│ │ ├── .venv/
│ │ └── main.py
│ ├── project_2/
│ │ ├── .venv/
│ │ └── main.py
│ ├── .gitignore
│ ├── README.md
│ └── myRepo/
├── project_1/
│ ├── .venv/
│ └── main.py
└── project_2/
├── .venv/
└── main.py