jupyter kernel error

5156
1
10-02-2019 09:23 AM
TimSemmelhaack
New Contributor III

Hi

after a while running the Jupyter Notebook on ArcGIS Pro 2.4.1 (Windows 10) on a cloned environment I geta Kernel error with the following message

Traceback (most recent call last):
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\web.py", line 1699, in _execute
    result = await result
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 742, in run
    yielded = self.gen.throw(*exc_info)  # type: ignore
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\notebook\services\sessions\handlers.py", line 72, in post
    type=mtype))
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 735, in run
    value = future.result()
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 742, in run
    yielded = self.gen.throw(*exc_info)  # type: ignore
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\notebook\services\sessions\sessionmanager.py", line 88, in create_session
    kernel_id = yield self.start_kernel_for_session(session_id, path, name, type, kernel_name)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 735, in run
    value = future.result()
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 742, in run
    yielded = self.gen.throw(*exc_info)  # type: ignore
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\notebook\services\sessions\sessionmanager.py", line 101, in start_kernel_for_session
    self.kernel_manager.start_kernel(path=kernel_path, kernel_name=kernel_name)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 735, in run
    value = future.result()
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\tornado\gen.py", line 209, in wrapper
    yielded = next(result)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\notebook\services\kernels\kernelmanager.py", line 168, in start_kernel
    super(MappingKernelManager, self).start_kernel(**kwargs)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\jupyter_client\multikernelmanager.py", line 110, in start_kernel
    km.start_kernel(**kwargs)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\jupyter_client\manager.py", line 240, in start_kernel
    self.write_connection_file()
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\jupyter_client\connect.py", line 547, in write_connection_file
    kernel_name=self.kernel_name
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\jupyter_client\connect.py", line 212, in write_connection_file
    with secure_write(fname) as f:
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\contextlib.py", line 81, in __enter__
    return next(self.gen)
  File "C:\Users\xxxx\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone_zvbn_02\lib\site-packages\jupyter_client\connect.py", line 102, in secure_write
    with os.fdopen(os.open(fname, open_flag, 0o600), mode) as f:
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\xxxx\\AppData\\Roaming\\jupyter\\runtime\\kernel-9fe63dbc-8b8d-4bc1-98f9-1e8536e166bd.json'

The permission error at the end looks strange to me, because it is my user folder.

Any ideas?

Thanks

Tim

0 Kudos
1 Reply
Jose_NicolasBaene
New Contributor II

I had a similar issue while trying to launch Jupyter Kernel for ArcGIS Insights, the solution was to downade the jupyter_client library to a previous version:

conda install -c anaconda jupyter_client=5.3.1

Maybe it´ll help with your issu. Here is the github link were I found the answer

Kernel error: jupyter_client/connect.py AssertionError · Issue #4937 · jupyter/notebook · GitHub 

0 Kudos