No project description provided
Project description
Jupyter client
A Jupyter Server Contents Manager implementation that provides seamless integration with CS3 (Cloud Storage Synchronization and Sharing) storage systems. This allows Jupyter environments to directly interact with distributed storage backends that implement the CS3 API, such as CERNBox.
The package also includes a JupyterLab extension that adds CERNBox sidebar panels (Spaces, Shares) and a storage quota indicator to the file browser.
Overview
The CS3 Contents Manager extends Jupyter Server's file management capabilities to work with CS3-compatible storage systems. It provides a complete replacement for the default file-based contents manager, enabling users to open, edit, save, and manage notebooks and files stored in remote CS3 storage.
Architecture
The CS3 Contents Manager consists of several key components:
Core Components
-
CS3FileContentsManager (
cs3_contents_manager/filemanager.py)- Implements Jupyter's AsyncContentsManager interface
- Handles file and directory operations
- Contains methods that are significantly different then its upstream countpart.
-
UpstreamFileContentsManager (
cs3_contents_manager/upstreamlargefilemanager.py)- Main contents manager class
- Implements Jupyter's AsyncContentsManager interface
- Handles file and directory operations
- Contains methods where only the OS functionality is replaced and can be pushed upstream.
-
CS3FileSystem (
cs3_contents_manager/cs3fs/cs3fs.py)- CS3 storage abstraction layer
- Provides filesystem-like interface over CS3 APIs
- Handles low-level CS3 client operations
-
CS3FileManagerMixin (
cs3_contents_manager/fileio.py)- Base mixin providing common file operations
- Authentication and configuration management
- File I/O utilities
-
CS3FileCheckpoints (
cs3_contents_manager/filecheckpoints.py)- Checkpoint management for notebooks
- Backup and restore functionality
-
UpstreamLargeFileManager (
cs3_contents_manager/largefilemanager.py)- Specialized handling for large file uploads
- Chunked transfer support
JupyterLab Extension
The bundled labextension (@cs3org/cs3-jupyter) provides three plugins:
- Spaces - sidebar panel listing CERNBox Spaces (projects) the user has access to
- Shares - sidebar panel showing incoming and outgoing CERNBox shared folders
- Storage Quota - progress bar at the bottom of the file browser showing storage usage
Installation
Install from Source
git clone <repository-url>
cd jupyter-client
pip install -e .
Labextension Development
# Create fake EOS directories for testing
./setup-fake-eos.sh ./fake-eos
# Install the extension (pip install -e . also builds the labextension)
pip install -e .
# Alternative manual install
# jlpm install
# jlpm build
# jupyter labextension develop . --overwrite
# Verify the extension is loaded
jupyter labextension list
# Start JupyterLab
jupyter lab \
--ServerApp.root_dir='./fake-eos' \
--FileContentsManager.preferred_dir='user/<u>/<user>' \
--ServerApp.token=''
Configuration
Jupyter Server Configuration
Add the following to your jupyter_server_config.py:
from cs3_jupyter.cs3largefilemanager import CS3LargeFileManager
c.ServerApp.contents_manager_class = CS3LargeFileManager
c.CS3FileManagerMixin.host = '<host>'
c.CS3FileManagerMixin.tus_enabled = False
c.CS3FileManagerMixin.ssl_enabled = False
c.CS3FileManagerMixin.token_path = '/path/to/oauth.token'
c.CS3FileManagerMixin.auth_login_type = 'bearer'
c.CS3FileManagerMixin.authtokenvalidity = 3600
c.CS3FileManagerMixin.lock_not_impl = False
c.CS3FileManagerMixin.lock_as_attr = False
c.CS3FileManagerMixin.root_path = '/eos/user/r/rwelande'
c.CS3FileManagerMixin.client_id = 'rwelande'
c.CS3LargeFileManager.max_copy_folder_size_mb = 500
Authentication
The CS3 Contents Manager supports OAuth token-based authentication. Set up your authentication:
- Token File: Place your OAuth token in a file (default:
/tmp/cernbox_oauth.token) - Configure Token Path: Set
token_pathin your configuration - Refresh: If authentication fails at some point the client will attempt to read in case of an update.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cs3_jupyter-0.1.0.tar.gz.
File metadata
- Download URL: cs3_jupyter-0.1.0.tar.gz
- Upload date:
- Size: 125.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a65a129ea68523c4aec0493f293fed9d1c8af9bdc8e36377ce069eec75db4b55
|
|
| MD5 |
9a36e62b921a8c25d3ccd48ac94ed4e9
|
|
| BLAKE2b-256 |
44a540980e3ac87f6372b3a1ccbf7af366925e2f1de3e15a2305af1b426c4a27
|
Provenance
The following attestation bundles were made for cs3_jupyter-0.1.0.tar.gz:
Publisher:
release.yml on cs3org/jupyter-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
cs3_jupyter-0.1.0.tar.gz -
Subject digest:
a65a129ea68523c4aec0493f293fed9d1c8af9bdc8e36377ce069eec75db4b55 - Sigstore transparency entry: 1825279321
- Sigstore integration time:
-
Permalink:
cs3org/jupyter-client@ea5627ce8da41dcabef7ca45f4b9476f8c295cf9 -
Branch / Tag:
refs/tags/v0.0.1 - Owner: https://github.com/cs3org
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ea5627ce8da41dcabef7ca45f4b9476f8c295cf9 -
Trigger Event:
release
-
Statement type:
File details
Details for the file cs3_jupyter-0.1.0-py3-none-any.whl.
File metadata
- Download URL: cs3_jupyter-0.1.0-py3-none-any.whl
- Upload date:
- Size: 62.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1d582a1cd6c45d120a9f178bb6765a39f480059d6f565426396fc7b9bb66544e
|
|
| MD5 |
5b1e1267f44d8b73631f06f798ecc206
|
|
| BLAKE2b-256 |
d5eeb57f089216a2b5bfe599c61dc526c6a075a35d868da44be0e54b1e0cd04f
|
Provenance
The following attestation bundles were made for cs3_jupyter-0.1.0-py3-none-any.whl:
Publisher:
release.yml on cs3org/jupyter-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
cs3_jupyter-0.1.0-py3-none-any.whl -
Subject digest:
1d582a1cd6c45d120a9f178bb6765a39f480059d6f565426396fc7b9bb66544e - Sigstore transparency entry: 1825279435
- Sigstore integration time:
-
Permalink:
cs3org/jupyter-client@ea5627ce8da41dcabef7ca45f4b9476f8c295cf9 -
Branch / Tag:
refs/tags/v0.0.1 - Owner: https://github.com/cs3org
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ea5627ce8da41dcabef7ca45f4b9476f8c295cf9 -
Trigger Event:
release
-
Statement type: