Skip to main content

providing contents from multiple sources in jupyter notebook

Project description

Multicontents

Build Status codecov

It's intentionally to do things like HybridContentsManager (from pgcontents) which allow setting up multiple sources on jupyter. With extra features including:

  • Support moving data accross different sources
  • The package is pretty lightweight, which means you don't need to install extra library if you only want the multi backend support.

Install

  1. install multicontents
pip install multicontents
  1. configure jupyter_notebook_config.py
from multicontents import MultiContentsManager
from IPython.html.services.contents.filemanager import FileContentsManager
from s3contents import S3ContentsManager

c.NotebookApp.contents_manager_class = MultiContentsManager
c.MultiContentsManager.managers = {
    "home": {
        "manager_class": FileContentsManager,
        "kwargs": {
            "root_dir": os.environ["HOME"]
        },
    },
    "s3": {
        "manager_class": S3ContentsManager,
        "kwargs": {
            "bucket": "example-bucket",
            "prefix": "path/to/notebooks",
        },
    },
}

Develoop

  1. clone the repo: git clone git@github.com:lydian/multicontents.git
  2. run testing with make server
  3. You can modify example config file for testing

I'll try my best to do CR pull request!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

multicontents-0.5.0.tar.gz (11.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

multicontents-0.5.0-py3-none-any.whl (13.5 kB view details)

Uploaded Python 3

File details

Details for the file multicontents-0.5.0.tar.gz.

File metadata

  • Download URL: multicontents-0.5.0.tar.gz
  • Upload date:
  • Size: 11.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for multicontents-0.5.0.tar.gz
Algorithm Hash digest
SHA256 159c9d8a3e5970012de4e88414b55a4181bd93dd1e8897fdbf34b8e0477f2223
MD5 017650a8b9886dbc1cf2bab208f47618
BLAKE2b-256 61c0359229fd503663f911c5bc3e25b1cd880be44c23c19046ed700ce9a67ee3

See more details on using hashes here.

File details

Details for the file multicontents-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: multicontents-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 13.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for multicontents-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2808c0a57d98d5e0622066202e6417e515b608df7ea19ffda9993f8247515f3a
MD5 9860653cad378d356872fe9eefc637dc
BLAKE2b-256 ee3be34ac3f3b9434077f7ec74b0ba039b60bbe2b85e06437d63c1562c427e3c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page