QuantStack / jupyterlab-blockly

Blockly extension for JupyterLab
https://jupyterlab-blockly.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
56 stars 16 forks source link

Kernel controls #26

Closed hbcarlos closed 2 years ago

hbcarlos commented 2 years ago

When the kernel hangs because of an infinite loop or any error in the code, we can not restart it. Would be great to support the actions from the Kernel menu. When closing the kernel, the dropdown to change kernels doesn't change.

hbcarlos commented 2 years ago

Adding here some useful info on how to activate the Kernel Menu for our blockly editor.

First, we need to register new commands that will be executed when the user clicks on one of the buttons: https://github.com/jupyterlab/jupyterlab/blob/d32ccb29f724eb537e042a34afd47820d1b52a5c/packages/notebook-extension/src/index.ts#L2518-L2559

Then we need to add the new commands to the kernel menu: https://github.com/jupyterlab/jupyterlab/blob/d32ccb29f724eb537e042a34afd47820d1b52a5c/packages/notebook-extension/src/index.ts#L2995-L3019