Reputation: 349
I installed a copy of Anaconda to play around with, but decided I liked Homebrew better, so I removed it. However, this seems to have messed up my install of Jupyter Notebooks, as I can no longer access it. I reinstalled it with pip install jupyter
and when I run pip show jupyter
I get:
Version: 1.0.0
Summary: Jupyter metapackage. Install all the Jupyter components in one go.
Home-page: http://jupyter.org
Author: Jupyter Development Team
Author-email: [email protected]
License: BSD
Location: /usr/local/lib/python2.7/site-packages
Requires: ipywidgets, nbconvert, notebook, jupyter-console, qtconsole, ipykernel
But when I run which -a jupyter
I get nothing. I even tried uninstalling and installing python again via Homebrew and it still gives me the error, -bash: jupyter: command not found
.
I have python installed correctly, which -a python
gives:
/usr/local/bin/python
/usr/bin/python
Any ideas as to why it might not be working?
Upvotes: 0
Views: 18737
Reputation: 642
On Mac OS Mojave,
pip3 install jupyter
installs jupyter
under
/Library/Frameworks/Python.framework/Versions/3.5/bin/
. Your version may be different from 3.5
. You can then link to the binary there as follows.
ln -s /Library/Frameworks/Python.framework/Versions/3.5/bin/jupyter /usr/local/bin/
In the rare case that /usr/local/bin/
is not on your PATH
, you may replace it above with some folder that is.
Upvotes: 2
Reputation: 53169
I'm on Mac and am using Zsh. For some reason, after I installed Python3, the following line:
PATH="/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}"
was added to .zprofile
instead of .zshrc
.
I transferred the line to .zshrc
and did source ~/.zshrc
. That did the trick.
Upvotes: 9
Reputation: 1376
The below command seems to install only python files (under /usr/local/lib/python2.7/site-packages in your case):
pip install jupyter
You can run the jupyter as a Python's module like this:
python -m jupyter
To see all installed modules you can type the following command from the Python's shell:
help('modules')
As an alternative you can try to upgrade the package:
pip install --upgrade pip
pip install --upgrade jupyter
If you want to access the jupyter by simply typing jupyter in your shell then the path to the jupyter's binary file should be placed inside the PATH variable.
During the installation of Anaconda software the jupyter binary is placed under /usr/local/bin/jupyter (Ubuntu 14.04).
Upvotes: 4