korniichuk / rk

The remote Jupyter kernel/kernels administration utility
http://www.korniichuk.com
The Unlicense
54 stars 18 forks source link

Question: Error ``ImportError: No module named IPython.kernel.zmq.kernelapp`` on a remote machine #4

Closed fonnesbeck closed 8 years ago

fonnesbeck commented 9 years ago

I've followed the setup steps, and confirmed that I can log in to my remote host without a password, but when I run Jupyter and switch to the remote kernel, I get the following:

Traceback (most recent call last):
  File "/usr/local/bin/rkscript", line 218, in <module>
    remote_ports = ch.receive()
  File "/usr/local/lib/python3.4/site-packages/execnet/gateway_base.py", line 711, in receive
    raise self._getremoteerror() or EOFError()
execnet.gateway_base.RemoteError: Traceback (most recent call last):
  File "<string>", line 1039, in executetask
  File "<string>", line 1, in do_exec
  File "<remote exec>", line 11, in <module>
ImportError: No module named IPython.kernel.zmq.kernelapp

Perhaps a PYTHONPATH issue?

Running Python 3.4 on OX X 10.11 locally.

fonnesbeck commented 9 years ago

I see that this is a remote error, however when I try import IPython.kernel.zmq.kernelapp on the remote machine, it does not give an error.

korniichuk commented 8 years ago

Error: ImportError: No module named IPython.kernel.zmq.kernelapp. Yep, it is a remote error. The IPython.kernel package has been deprecated. My code from the rkscript:

try:
    from ipykernel.kernelapp import launch_new_instance
except ImportError:
    from IPython.kernel.zmq.kernelapp import launch_new_instance

Check this python 2 and python 3 modules or reinstall/update the jupyter notebook on a remote machine.