'kernel failed to start using conda environment with Jupyter in Visual Studio Code

When using a Jupyter notebook file in Visual Studio code with the Jupyter extension I receive the error The kernel failed to start due to the missing module 'ipykernel_launcher'. Consider installing this module. View Jupyter [log](command:jupyter.viewOutput) for further details.

This notebook works correctly from the JupyterLab web application when I select the same conda environment that was selected in Visual Studio Code.

pip list shows that ipykernel version 5.3.4 is installed, but I don't know how to install ipykernel_launcher. I tried reinstalling pyzmq and it didn't help.

Any ideas why this isn't working?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source