How to uninstall Jupyter notebook that was install

2019-06-24 11:59发布

问题:

I've installed anaconda and that came with its own Jupyter version so I want to uninstall the Jupyter that I installed using pip3. I searched for instruction and tried using pip3 uninstall Jupyter, but that does not seem correct because I get the following, which it says is Jupyter 1.0.0:

Uninstalling jupyter-1.0.0:
  /usr/local/lib/python3.6/site-packages/__pycache__/jupyter.cpython-36.pyc
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/DESCRIPTION.rst
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/INSTALLER
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/METADATA
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/RECORD
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/WHEEL
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/metadata.json
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/pbr.json
  /usr/local/lib/python3.6/site-packages/jupyter-1.0.0.dist-info/top_level.txt
  /usr/local/lib/python3.6/site-packages/jupyter.py

I know I can also try pip3 uninstall notebook, but that shows a bunch of files that I'm not sure is actually Jupyter.

This must seem like such a simple question, but I've searched and haven't found clear answer. Thank you!

回答1:

Unfortunately there's no simple solution. The "pip install jupyter" command installs various dependencies and so you'll probably have to uninstall them all seperately.

The packages associated with Jupyter are:

  • notebook
  • nbconvert
  • nbformat
  • ipykernel
  • ipywidgets
  • qtconsole
  • traitlets
  • tornado
  • anything with jupyter in front of it (jupyter_core, jupyter_client etc.)
  • ipython_genutils
  • jinja2

Some of these aren't Jupyter only (tornado, qtconsole, jinja2 etc) but if you're sure you're not using them then feel free to uninstall.