xoroth
xoroth

Reputation: 31

Can't use python base environment in vs code

env list vs code env list

The base environment isn't shown in my vs code, and in vs code, it has an environment named "Miniconda3". When I try to run .ipynb files in vs code, I get this error:

Error: Activating Python 3.7.3 64-bit ('Miniconda3': conda) to run Jupyter failed with Error: Command failed: d:/Miniconda3/Scripts/activate && conda activate Miniconda3 && echo 'e8b39361-0157-4923-80e1-22d70d46dee6' && python c:/Users/****/.vscode/extensions/ms-python.python-2019.11.50794/pythonFiles/printEnvVariables.py Could not find conda environment: Miniconda3 You can list all discoverable environments with conda info --envs.

How can I solve this without creating new environment?

Upvotes: 0

Views: 1054

Answers (1)

Brett Cannon
Brett Cannon

Reputation: 16080

You need to create an environment with a Python version specified so conda installs a Python interpreter, e.g. conda create -n <yourenvname> python=3.8.

The details of where the extension looks for environments can be found in the environments docs.

Upvotes: 0

Related Questions