We have just released version 4.2 of the Jupyter Notebook. The Jupyter Notebook is a web application that allows you to create and share documents that contain live code, equations, visualizations and explanatory text (see the Jupyter project home page for more information).
Version 4.2 of the notebook has many bugfixes and improvements. You can see a summary of changes in the docs, or see all the changes on GitHub.
Altogether, 21 authors contributed to 53 pull requests to make this release.
The notebook extension system was improved greatly in version 4.2. The notebook can be extended in two ways:
- nbextensions, which are JavaScript extensions that run in your browser. These can modify the UI or behavior of the notebook, such as adding buttons to your toolbar, new keyboard shortcuts, etc.
- serverextensions, which modify the Python webserver. These can add new HTTP endpoints, register extra events to run when you save your notebook, etc.
The improvements to the extension system are focused on making installing and enabling extensions easier, including:
- better symmetry between handling of serverextensions and nbextensions
- allowing enabling nbextensions system-wide
- working better with the Python
sys.prefix
for installing/enabling extensions using packages and environments, such as conda packages or python wheels - allowing installation via Python packages
In general, installing and enabling extensions is a two-step process:
install the extension:
jupyter nbextension install /path/to/myextension
enable the extension
jupyter nbextension enable myextension/main
Installation is system-wide by default, but you can specify an installation to be just for you with --user
. Enabling an extension is per-user by default, but you can enable an extension system-wide with --system
. You can install or enable an extension using the Python sys.prefix
by using the --sys-prefix
option available in either command. For example, to make a conda package that includes an extension, you should install the extension using --sys-prefix
when building the package.
Python packages can specify information about what nbextensions and serverextensions they provide. These can be installed with:
jupyter nbextension install --py packagename
jupyter serverextension enable --py packagename
For more information on installing extensions from Python packages, see the docs.
Edit: updated to add a link to the main Jupyter webpage, based on feedback from HackerNews. Thanks!