1

Whenever I have previously run Jupyter notebooks from within an activated conda environment, the environment is available within Jupyter. However, now when I do this with any newly created environment this doesn't work anymore. If I use a previously created environment I can access the environment through Jupyter, it is only newly created environments which don't work!

I have tried installing nb_conda_kernels ipykernel and ipywidgets as described in another stack overflow question but this also doesn't solve the issue.

Any ideas how I can get this working again and which packages might not be installed for this to work?

Edit: If I follow the top answer on this post Conda environments not showing up in Jupyter Notebook then the environment becomes available. However I would need to run this for every new environment! Any reason this behavior could have changed?

speeder1987
  • 185
  • 1
  • 10

2 Answers2

2

Try this

conda create --name firstEnv
conda activate firstEnv
conda install -c anaconda ipykernel
python -m ipykernel install --user --name=firstEnv
Raj Patel
  • 114
  • 6
  • 1
    Thanks, it turns out it was problem with the Jupyter and Ipykernel packages in the base Conda environment which I should have thought of checking before posting! – speeder1987 May 13 '22 at 08:55
0

For anyone else having this problem I solved this by reinstalling the Jupyter and Ipykernel packages in the base conda environment.

speeder1987
  • 185
  • 1
  • 10