I have a problem that I have been going around for an hour yet I'm sure it's very simple:
my pip installs all the libraries in a mkdir ~/local/bin
and not in my PATH
I delete it and re-install with python -m pip uninstall pip
But nothing to do he always installs me in local
The problem is when I do pip install jupyter
jupyter-notebook is not in my Path and when I execute
./jupyter-notebook in local / bin then I have the following answer:
Traceback (most recent call last): File "./jupyter-notebook", line 11, in sys.exit(main()) File "/home_local/isduser/.local/lib/python2.7/site-packages/jupyter_core/application.py", line 268, in launch_instance
You are a local user and not an administrator and yuou do not seem to use pyenv or virtualenvs.
pip cannot install anything in the system path as you just don't have the permissions for it.
Therefore pip installs in your local path.
If I recall correctly it should be enough to add (prepend) ~/.local/bin to your search path.
Just type
ls ~/.local/bin/jupyter-notebook
and check wether the command is found or not.
If the command is not found, then I suggest to use virtualenvs and either direnv or autoenv to activate your virtualenvs.
Tell me whether my first suggestion works. If not, then I'll guide you through virutalenv.
To see if there are already other notebooks running you can type
jupyter-notebook list
To start the notebook on another port use:
jupyter-notebook --port port_number
Yes thank you very much for your answer
actually when i do ls ~ .local / bin there is jupyter notebook in this folder So I added it to my PATH export PATH = "~ .local / bin: $ PATH" But now I have this problem when I execute jupyter notbook
➜ ~ jupyter-notebook
Traceback (most recent call last):
File "/home_local/isduser/.local/bin/jupyter-notebook", line 11, in <module>
sys.exit(main())
File "/home_local/isduser/.local/lib/python2.7/site-
packages/jupyter_core/application.py", line 268, in launch_instance
return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
File "/home_local/isduser/.local/lib/python2.7/site-
packages/traitlets/config/application.py", line 663, in launch_instance
app.initialize(argv)
File "</home_local/isduser/.local/lib/python2.7/site-
packages/decorator.pyc:decorator-gen-7>", line 2, in initialize
File "/home_local/isduser/.local/lib/python2.7/site-
packages/traitlets/config/application.py", line 87, in catch_config_error
return method(app, *args, **kwargs)
File "/home_local/isduser/.local/lib/python2.7/site-
packages/notebook/notebookapp.py", line 1630, in initialize
self.init_webapp()
File "/home_local/isduser/.local/lib/python2.7/site-
packages/notebook/notebookapp.py", line 1407, in init_webapp
self.http_server.listen(port, self.ip)
File "/home_local/isduser/.local/lib/python2.7/site-
packages/tornado/tcpserver.py", line 143, in listen
sockets = bind_sockets(port, address=address)
File "/home_local/isduser/.local/lib/python2.7/site-
packages/tornado/netutil.py", line 168, in bind_sockets
sock.bind(sockaddr)
File "/usr/lib/python2.7/socket.py", line 228, in meth
return getattr(self._sock,name)(*args)
socket.error: [Errno 99] Cannot assign requested address
I tried to have a virtual venv i reinstall jupyter and i've the seem problem upper when i execute jupyter-notebook
howewer j'ai supprimer older jupyter notebook in .local/bin
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.