问题
i am trying to use jupyter notebooks from vs code and installed jupyter notebook extension and i am using (base)conda environment for execution. while this happened
Error: Jupyter cannot be started. Error attempting to locate jupyter: at A.startServer (c:\Users\DELL.vscode\extensions\ms-python.python-2020.2.63990\out\client\extension.js:1:784356) at async A.ensureServerAndNotebookImpl (c:\Users\DELL.vscode\extensions\ms-python.python-2020.2.63990\out\client\extension.js:1:783811) at async A.ensureServerAndNotebook (c:\Users\DELL.vscode\extensions\ms-python.python-2020.2.63990\out\client\extension.js:1:783612) at async A.submitCode (c:\Users\DELL.vscode\extensions\ms-python.python-2020.2.63990\out\client\extension.js:1:780564) at async A.reexecuteCell (c:\Users\DELL.vscode\extensions\ms-python.python-2020.2.63990\out\client\extension.js:75:879318)
how to resolve this issue ?
回答1:
I had exactly the same problem when I installed Visual Studio Code and tried to run some Python code from a jupyter notebook on my fresh Ubuntu 18.04.
How I solved it:
1) Press Command+Shift+P to open a new command pallete
2) Type >Python: Select Intepreter to start jupyter notebook server
3) Open the notebook again
And it worked fine. Hope it works for you.
回答2:
Press Command+Shift+P
Type
Python: Select Interpreter to start Jupyterserver
It would show you a dropdown of python versions installed.
I chose python 3.7.5 and it worked for me.
回答3:
I have several versions of Python installed. It happened the same thing to me and I have fixed it this way. Ctrl+Shift+p and select Python: Select Interpreter to start Jupyter server
Then, select the version under the Visual Studio Code
Nothing will happen and then press again Ctrl+Shift+p and select Python: Create new blank Jupyter Notebook. And it works
I have even set the Python version to 3.8 at the bottom and it worked too with the new features print(a:=4) despite the fact that the version I have chosen was 3.7.5. Nevertheless, I have to lunch VS Code from Anaconda Navigator.
回答4:
I faced the same problem and this solved my problem https://www.reddit.com/r/vscode/comments/eq2bfv/vs_code_jupyter_server_no_kernel_python_not/ hope this helps
回答5:
I tried the following:
- Press
Command + SHIFT + P - Type
Python: Select Interpreter to start Jupyterserver
Hope this answer was helpful.
来源:https://stackoverflow.com/questions/60330837/jupyter-server-not-started-no-kernel-in-vs-code