Voila prerender doesn't support markdown JupyterLab commands
Opened this issue · 1 comments
davidkan6666 commented
When using markdown cells containing JupyterLab commands, after being rendered by Voila, the required JavaScript libraries appear no longer available and result in errors like:
Command 'notebook:clear-all-cell-outputs' not registered
Command 'help:about' not registered
How to reproduce it?
- create a test notebook
- add the following code in Markdown cell:
<button data-commandLinker-command="notebook:run-all-below" href="#">START</button> <button data-commandLinker-command="kernelmenu:interrupt" href="#">STOP</button> <button data-commandLinker-command="notebook:clear-all-cell-outputs" href="#">CLEAR</button> <button data-commandLinker-command="help:about" href="#">About</button>
- run the cell in the notebook
- buttons work
- now open notebook with Voila Prerender
- click on any button will result in something like "Uncaught (in promise) Error: Command 'help:about' not registered" from developer tool (F12) Console.
- voila version 0.5.7
- Operating System and version: Microsoft Windows 10
- Browser and version: Chrome Version 128.0.6613.139 (Official Build) (64-bit) and FireFox 130.0.1 (64-bit)
Browser Output
2168.voila.js:1 Uncaught (in promise) Error: Command 'help:about' not registered. at d.execute (2168.voila.js:1:2959) at L._evtClick (1024.voila.js:1:35883) at L.handleEvent (1024.voila.js:1:35512) 2168.voila.js:1 Uncaught (in promise) Error: Command 'notebook:run-all-below' not registered. at d.execute (2168.voila.js:1:2959) at L._evtClick (1024.voila.js:1:35883) at L.handleEvent (1024.voila.js:1:35512) 2168.voila.js:1 Uncaught (in promise) Error: Command 'kernelmenu:interrupt' not registered. at d.execute (2168.voila.js:1:2959) at L._evtClick (1024.voila.js:1:35883) at L.handleEvent (1024.voila.js:1:35512) 2168.voila.js:1 Uncaught (in promise) Error: Command 'notebook:clear-all-cell-outputs' not registered. at d.execute (2168.voila.js:1:2959) at L._evtClick (1024.voila.js:1:35883) at L.handleEvent (1024.voila.js:1:35512)
- JupyterLab version: 4.2.5
Installed Labextensions
jupyterlab_pygments v0.3.0 enabled OK (python, jupyterlab_pygments) @jupyter-widgets/jupyterlab-manager v5.0.13 enabled OK (python, jupyterlab_widgets) @voila-dashboards/jupyterlab-preview v2.3.7 enabled OK (python, voila) @jupyter-notebook/lab-extension v7.1.3 enabled OK
fomightez commented
Discussion thread related to this issue is here on the Jupyter Discourse Forum.