The classic notebook as a server extension.
This repo is experimental and meant to demonstrate how the notebook could be launched as a frontend+server extension. It is a fork of the classic notebook, refactored to use the jupyter_server
and jupyter_server_extension
dependencies.
Important: use a virtual environment to avoid messing with your actually notebook installation.
-
Run the notebook app directly.
jupyter notebook
-
Use jupyter server to launch the notebook.
Make sure the notebook is enabled.
jupyter server extension list jupyter nbextension list
If the frontend extensions or server extension is not enabled, enable them!
# Enable the frontend extension jupyter nbextension enable notebookext --sys-prefix # Enable the server extension jupyter server extension enable notebookext
Then run with the default URL set to the notebook tree:
jupyter server --default_url="/tree"
Here's a short list of what's happening"
- All handlers inherit from the
JupyterExtensionHandler
(i.e. see here) NotebookApp
inherits fromJupyterExtensionApp
.load_jupyter_server_extension
loads config and appends handlers to jupyter server.