nteract / nteract

📘 The interactive computing suite for you! ✨

Home Page:https://nteract.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Kernel auto-restarts should probably be detected and an action raised

shibbas opened this issue · comments

Happy to contribute the fix to nteract.

Application or Package Used
nteract on jupyter, and nteract packages.

Describe the bug
Nteract does not seem to detect kernel auto-restarts like Jupyter. It allows cell execution to continue but the cell that triggered restart gets stuck in [*]

To Reproduce
Run the following code in jupyter vs. nteract:

import os; os._exit(1)

Expected behavior
Cell execution clears on kernel auto-restart and an KERNEL_AUTO_RESTARTED action should probably be raised so that apps using the packages can detect and show "Kernel restarted" message.

Note from meeting: jupyter server being discussed. Autorestarting tests.

Thanks for the meeting @willingc @CodeSeal. Here are the links to the Jupyter auto-restart tests: https://github.com/jupyter/notebook/blob/56416cbd2ddc92feba1978f21efb29da6406f40a/notebook/tests/services/kernel.js#L285

And the notebook config option for the kernel restart:

KernelManager.autorestartBool
Default: True
Should we autorestart the kernel if it dies.