pythonpython-3.xvisual-studio-codevirtualenvenvironment

Why are there double parentheses around my Python virtual environment in Visual Studio Code?


After updating Visual Studio Code to version 1.88.0, I opened one of my Python projects and noticed that there are double parentheses in my virtual environment: ((env) ).

I'm using the Python extension v2024.4.0

enter image description here

Previously, in the same and all other projects, I had only one pair of parentheses like (env). I have checked, but I didn't find any information about it. I have read that (venv1) (venv2) indicates a double virtual environment, but I don't know if this is the case.

I have tried deleting the env (I have the requirement.txt) or closing/reopening VSCode, but the problem persists. Any suggestions on how to fix it?

I have checked the files: .bashrc, .zshrc, .bash_profile, but everything seems fine. Also, by starting a new project from scratch, the problem persists.


Solution

  • It's an issue with the Python extension v2024.4.0. Reverting to the previous version, v2024.2.1, fixed this issue for me.

    image of python extension for vs code