Skip to main content

Tools for Google Colab and Jupyter notebooks.

Project description

The oxlab package provides tools for Google Colab and Jupyter notebooks.

Sometimes you want to be able to use or distribute private GitHub repos in Jupyter notebooks that people may run on their local systems or in Google Colab. This project provides a simple way to accomplish that goal.

Imagine you have an example notebook called oxlab_demo.ipynb and you want to have it reference a private GitHub repo for your project.

You can take the following steps:

  1. Generate an SSH deploy key for your project via something like:

    ssh-keygen -t ecdsa -f /tmp/example_deploy_key_id_ecdsa
  2. Upload the public key (/tmp/example_deploy_key_id_ecdsa.pub) if you used the above command to GitHub as discussed in the instructions on deploy keys.

  3. Create a cell in your notebook like the following where you replace $YOUR_PRIVATE_KEY with you ssh deploy key generated in step 1 (e.g., the contents of /tmp/example_deploy_key_id_ecdsa), replace $OWNER with the owner of your GitHub repo (e.g., emin63) and $REPO with your repo (e.g., oxlab):

    # @title Pull in our private github repo
    SSH_DEPLOY_KEY = $YOUR_PRIVATE_KEY
    !pip install oxlab
    import oxlab
    oxlab.add_github_repo($OWNER, $REPO, SSH_DEPLOY_KEY)
  4. Then the remainder of your notebook will be able to reference your repo contents.

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

oxlab-0.2.0.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

oxlab-0.2.0-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file oxlab-0.2.0.tar.gz.

File metadata

  • Download URL: oxlab-0.2.0.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.13

File hashes

Hashes for oxlab-0.2.0.tar.gz
Algorithm Hash digest
SHA256 ea2a129544ba14f6cac5acc39e92a38736d3f460e99b11965b26024ff1f32308
MD5 227f8a140a3301022b83fc6185c8c225
BLAKE2b-256 41ad80b2487b184db61b7a710ba4669f65860498631a563dc8739234c979584a

See more details on using hashes here.

File details

Details for the file oxlab-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: oxlab-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 5.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.13

File hashes

Hashes for oxlab-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0e628ba16e85e9fc4f28b0f352e3dcc990a01c6f2f5d57324738864ac4bf6ba5
MD5 0b6ca193029e6212be6cacb5b7803149
BLAKE2b-256 96fab277e2bbe494c3b42cbb036612d8779a4230846b85f0c6964a5dc2b4d04a

See more details on using hashes here.

Supported by

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