Hi @AshwinKAshok - Since Kernel Gateway only launches local kernels (to itself) this answer would be similar to Notebook relating kernel_ids to processes since JKG is essentially the same implementation (just headless, except that the kernel management takes place on the JKG server).
I don’t know of a way to do this with Notebook and nowhere in the framework is the kernel-pid surfaced AFAIK. Do you know of a way to accomplish this using standard Notebook?
Of course, kernel management knows this relationship (jupyter_client in particular), but the pid is rarely used internally (the Popen instance is used for signals and polling).
/api/kernels
and /api/kernelspecs
endpoints.)/api/kernels/{kernel-id}
and the gathering been done in MappingKernelManager
where activity recording occurs, this would just work because that api is handled by gateway servers (JKG and EG).MappingKernelManager
- which has direct access (via the KernelManager
instance) to the kernel process.@/all - [ANN] Notebook 6.1.0 is available!
The Notebook 6.1.0 release is now available! You can catch up on the changes here.
This release culminates in a substantial community effort with nearly 60 different contributors. Thank you to all those that contributed, raised issues, and participated in its success!
To get 6.1.0:
For pip-managed installations:
new: pip install notebook
existing: pip install --upgrade notebook
For conda-managed installations:
new: conda install -c conda-forge notebook
existing: conda update -c conda-forge notebook
IPython.display.HTML(...)
, so I am thinking maybe we can also support that in Jupyter notebook by detecting quoted string inside HTML()
in a code block. Could you please give me some hints?
Hi, I am having a very weird problem trying to run Jupyter notebook from a server via SSH port forwarding.
Anybody with any idea on what I could try next would be really great...
ssh -v -v -v
:debug2: channel 2: read<=0 rfd 9 len 0
debug2: channel 2: read failed
debug2: channel 2: chan_shutdown_read (i0 o0 sock 9 wfd 9 efd -1 [closed])
debug2: channel 2: input open -> drain
debug2: channel 3: read<=0 rfd 10 len 0
debug2: channel 3: read failed
debug2: channel 3: chan_shutdown_read (i0 o0 sock 10 wfd 10 efd -1 [closed])
debug2: channel 3: input open -> drain
debug2: channel 2: ibuf empty
debug2: channel 2: send eof
debug3: send packet: type 96
debug2: channel 2: input drain -> closed
debug2: channel 3: ibuf empty
debug2: channel 3: send eof
debug3: send packet: type 96
debug2: channel 3: input drain -> closed
...
jupyter notebook
I'm getting a KeyError on 'color', has anyone seen this?--- Logging error ---
Traceback (most recent call last):
File "/usr/lib/python3.6/logging/__init__.py", line 994, in emit
msg = self.format(record)
File "/usr/lib/python3.6/logging/__init__.py", line 840, in format
return fmt.format(record)
File "/home/osboxes/jupyter/notebook/.tox/lib/python3.6/site-packages/traitlets/config/application.py", line 117, in format
return super(LevelFormatter, self).format(record)
File "/usr/lib/python3.6/logging/__init__.py", line 580, in format
s = self.formatMessage(record)
File "/usr/lib/python3.6/logging/__init__.py", line 549, in formatMessage
return self._style.format(record)
File "/usr/lib/python3.6/logging/__init__.py", line 391, in format
return self._fmt % record.__dict__
KeyError: 'color'
Hi, I'm having difficulty switching conda environments while running a jupyter notebook. I first created a 2nd env, installed ipykernel in that environment, and created a 2nd kernel.
Shut down all kernels, open my notebook and choose the 2nd kernel (env2), but running the notebook, i can see that the old the commands are being run under the previous env, as demonstrated with a !conda env list.
as a test, i've ran it as a list. It seems like every subsequent command is run from a default shell.
!conda env list
!source /opt/conda/etc/profile.d/conda.sh && conda activate testy && conda env list
!conda env list
will show:
conda environments:
#
base * /opt/conda
testy /opt/conda/envs/testy
conda environments:
#
base /opt/conda
testy * /opt/conda/envs/testy
conda environments:
#
base * /opt/conda
testy /opt/conda/envs/testy
Preparing transaction: done
Verifying transaction: done
Executing transaction: failed
ERROR conda.core.link:_execute(502): An error occurred while uninstalling package 'conda-forge::notebook-4.2.3-py35_0'.
OSError(16, 'Device or resource busy')
Attempting to roll back.
Rolling back transaction: done
OSError(16, 'Device or resource busy')