I have created multiple miniconda environments in my macbook. But when I open jupyter notebook, it shows non-existent conda environments I created long ago and which are no longer available in conda environments.
How to remove these non-existing environment names from jupyter notebook?
My current conda list
What Jupyter Shows
(NOTE: For example, Jupyter notebook shows environment "xx" which is not in conda env list)
How to remove non-existent environments
How to remove non existing environment such as "xx" from showing up when I open jupyter notebook?
It depends on how you registered the kernel, but I suspect you used the
python -m ipykernel install --user
. In that case, you should be able to get a list of where the kernels are registered withand you can simply delete the folders corresponding to kernels you wish to delete.
It may be worth noting that using
nb_conda_kernels
to auto-register all Conda envs withipykernel
would automatically remove kernels when you delete their environments or remove theipykernel
from the environment.