When Cursor composer agent (in a python project) is doing something in the current project, it should be using the current venv - it runs things like pip install
without activating the current venv, which causes it to modify a global environment.
2 Likes
Are you telling it to use a specific venv?
It works for me. I recently asked it to create a conda environment and use that for the project and it generated and executed commands like this:
source ~/.bash_profile && conda activate torch && pip install torch torchvision torchaudio pytorch-lightning tensorboard albumentations
This is annoying. The Python path selected in “Python: Select Interpreter” is not used.
2 Likes
Yeah this one is hard to navigate around, I can’t run tests without being in the venv and have tried prompting cursor to create a venv within its own context