Notebook Shim

0.2.4 · active · verified Sun Mar 29

Notebook-shim is a Python library that provides a compatibility layer for applications transitioning from `jupyter/notebook` to `jupyter/jupyter_server` as their backend. It specifically helps handle traits and configuration that moved between these two core Jupyter components. The current version is 0.2.4, and it is released on an as-needed basis to support the evolution of the Jupyter ecosystem.

Warnings

Install

Imports

Quickstart

This quickstart demonstrates the primary use case of `notebook-shim`: integrating `NotebookConfigShimMixin` into an application that now extends `jupyter_server.serverapp.ServerApp` instead of the legacy `notebook.notebookapp.NotebookApp`.

from jupyter_server.serverapp import ServerApp
from notebook_shim import NotebookConfigShimMixin

class MyShimmedApp(NotebookConfigShimMixin, ServerApp):
    # Your application's custom logic here
    pass

if __name__ == '__main__':
    # In a real application, you would run this via `jupyter-server` entrypoints.
    # For a direct example, you can instantiate and start it minimally.
    print("This example demonstrates the import path and class inheritance.")
    print("To run a functional server, integrate MyShimmedApp with jupyter_server's extension system.")

view raw JSON →