-
Notifications
You must be signed in to change notification settings - Fork 297
Troubleshooting (WIP)
Don Jayamanne edited this page Mar 10, 2022
·
14 revisions
TODO:
- Review https://github.com/microsoft/vscode-jupyter/wiki/FAQ---(Frequently-Asked-Questions)
- https://github.com/microsoft/vscode-jupyter/wiki/Troubleshooting-Jupyter-issues-in-the-Python-Interactive-Window-or-Notebook-Editor
We're sorry you're having trouble and looking for a solution here. Here are a few tips to get you unblocked:
- Try switching to the pre-release version of the Jupyter extension. Its possible the issue has already been resolved in the development branch of the extension. Such fixes are available in the pre-release version of the extension (which gets published almost on a daily basis).
- Verify the same issue does not exist in Jupyter Notebook or Jupyter Lab. If the same problem exists in either one, then its most likely and environmental issue or the like. You might want to review the environment or the packages used, and file an issue on the appropriate repo or the like.
- Try updating the packages to the latest version. Some times, some Python packages may be outdated. It might not be easy to determine the out dated package, hence might be easier to simply create a new environment (virtual environment or a Conda environment) and try again.
- If you are running into problems with importing packages or kernel issues due to some packages, consider using
conda install
over pip. Based on our experience we've foundConda Environments
to be one of the most reliable ways to get Python packages installed. Also, please do not mix and matchpip
install withconda install
when usingconda environments
. - Please review some of the below sections to try and get the issue addressed.
- If all else fails, please do file an issue on the repo and we'd be happy to help you get unblocked.
- Confirm the Python extension has been installed when working with Python kernels.
- Confirm this same kernel can be found in Jupyter Lab/Notebook. If the kernel cannot be found in either one of these, then its unlikely to be found in VS Code. You might want to refer to the documentation related to the installation of kernels.
- If the Python Environment cannot be found in the list of kernels, verify this is listed in the list of Python Interpreters you get when you select the command
Python: Select Interpreter
. If the Python environment in question is not listed in there either, then its unlikely to be listed in the list of Kernels. Please file an issue against the Python extension here and we'll be happy to look into this issue and get you unblocked.
- IPyKernel and other dependencies are not installed
- Outdated version of IPython
- Outdated version of IPyKernel
- Failure to start kernel due to missing package pip
- Failure to start kernel when using Conda Environments
- ipykernel & other dependencies are installed, yet I am asked to install these dependencies
- Built in modules overridden by user code
- Module not installed
- Failure to import modules
- Dll load failures
- Errors with Win32api module
- Errors with pyzmq module
For a full list of all known issues, please see the list of issues here.
Please up-vote these issues to help us prioritize getting these addressed.
- The
OCAML
kernel does not work (#8897) - Kernels using
32-bit
Python environments installed viaconda
does not work (#9134) -
xeus
Python kernel is currently not supported (hence hidden) (#5469)
- Python packages do not load
- Verify the python package has been installed.
- Verify the python package can be loaded in the REPL.
- Verify the right kernel (Python environment) has been used to run the notebook.
- Verify you do not have any python files that could potentially override built-in modules such as
os.py
,random.py
,email.py
, and the like.
- Kernel crashes when running some code
- Verify you do not have any python files that could potentially override built-in modules such as
os.py
,random.py
,email.py
, and the like. - Verify the kernel does not always crash, and only crashes when running a specific cell or using a specific kernel. This helps narrow down the issue to a specific package or environment.
- It has been observed that some packages if incorrectly installed or found to be outdated, can result in the kernel crashing.
- Please verify the same code runs successfully in Jupyter Notebooks or Jupyter Lab. If it fails there too, please consider updating the packages to the latest versions or filing an issue against the corresponding repo or the like.
- Review the output in the
Jupyter
output panel to understand why the kernel may have crashed. The logs generally point to a Python package that caused the kernel to crash.
- Verify you do not have any python files that could potentially override built-in modules such as
- Built in modules overridden by user code
- Contribution
- Source Code Organization
- Coding Standards
- Profiling
- Coding Guidelines
- Component Governance
- Writing tests
- Kernels
- Intellisense
- Debugging
- IPyWidgets
- Extensibility
- Module Dependencies
- Errors thrown
- Jupyter API
- Variable fetching
- Import / Export
- React Webviews: Variable Viewer, Data Viewer, and Plot Viewer
- FAQ
- Kernel Crashes
- Jupyter issues in the Python Interactive Window or Notebook Editor
- Finding the code that is causing high CPU load in production
- How to install extensions from VSIX when using Remote VS Code
- How to connect to a jupyter server for running code in vscode.dev
- Jupyter Kernels and the Jupyter Extension