Lmod JupyterLab extension
Project description
Jupyter Lmod
Jupyter interactive notebook server extension that allows user to interact with environment modules before launching kernels. The extension use Lmod's Python interface to accomplish module related task like loading, unloading, saving collection, etc.
requirements
- jupyter notebook >= 6.0
- Lmod >= 6.0
- optional: jupyterlab >= 3.0
- optional: jupyter-server-proxy >= 3.2.0
- optional: jupyterlab-server-proxy >= 3.2.0
If jupyter-server-proxy and jupyterlab-server-proxy are detected, jupyter-lmod will add the proxy server launchers to JupyterLab UI when modules with matching names are loaded.
setup
install
pip install jupyterlmod
Disable jupyter-server-proxy notebook and lab extensions
To avoid having items in the launcher that cannot be launched because the binaries location are not in PATH, jupyter-lmod hides launcher items that do not have a corresponding loaded module. jupyter-server-proxy notebook and lab extension always display the launcher item. To avoid a situation where an item would be shown twice, we recommend disabling jupyter-server-proxy notebook and lab extensions.
This can be done with the following command for notebook:
jupyter nbextension disable --py jupyter_server_proxy --sys-prefix
and with the following commands for jupyterlab:
jupyter labextension disable @jupyterlab/server-proxy
jupyter labextension disable jupyterlab-server-proxy
Pinning launcher items
If server proxies do not have a corresponding modules, or you wish to have their launcher items displayed regardless of the loaded modules, you can define a list of items that will be pinned in the Jupyter notebook configuration file, like this:
c.Lmod.launcher_pins = ['Desktop', 'RStudio']
demo
develop
requirements
- pip >= 23
- build
- nodejs >= 18.x
build
- wheel and tarball:
pyproject-build
- labextension
cd jupyterlab npm install npm run build # To install extension in jupyterlab in develop mode: npm run install:extension
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for jupyterlmod-4.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9939bd7927c2c347f9884247bac58018ca44d56184c5f29e9d704a9b3a09a299 |
|
MD5 | 580f4d05bd2bf158e50c2abab2ff607e |
|
BLAKE2b-256 | eecd2ccfa6ece8f304852d6ba3535839b67ddcc907807c97e69a6061178d0b66 |