Unable to start jupyter notebook in visual studio code

Viewed 1990

I am trying to make a jupyter notebook in visual studio code but I keep getting this:

''Unable to start session for kernel Python 3.8.3 64-bit ('Lenovo': virtualenv). Select another kernel to launch with.''

I have anaconda installed and the jupyter notebook works fine in the anaconda navigator. I also tried to use python 3.8.3 base:'conda' but it didnt work. I'm using windows 10

3 Answers

This issue also occurs on my computer. The solution is to restore the version number of a dependency package "traitlets" of ipython kernel to 4.3.3.

You could try to use "pip list" to view the version of the module "traitlets" in the current virtual environment. If it shows version 5.0, it is recommended that you use version 4.3.3.

enter image description here

You could reinstall "traitlets 4.3.3" with the following command:

python -m pip install 'traitlets==4.3.3' --force-reinstall

If this command is not available, you could use 'pip' to uninstall traitlets5.0 (pip uninstall traitlets) and then use 'pip' to install traitlets4.3.3.(pip install traitlets==4.3.3)

Reference: Unable to start session for kernel Python.

I had the exact same problem. Fix it by uninstalling the Python extension that is linked to that error message.

If you are using conda to manage your Python environments, activate your target environment at a command prompt, then enter the following:

$ conda install traitlets=4.3.3

This solved the problem for me.

Related