Skip to main content

Jupyter kernel for the Michelson language

Project description

Michelson kernel

Docker Build Status made_with pytezos Binder

Jupyter kernel for the Michelson language

Features

  • Custom interpreter with runtime type checker
  • Syntax highlighter
  • Autocomplete by Tab
  • Inplace docstrings by Shift+Tab
  • Macros support
  • Verbose execution logging
  • Debug helpers

Purposes

  • Learning
  • Demonstration
  • Fast prototyping
  • Case investigation

How to install

Option 1: try online!

Powered by awesome Binder: https://mybinder.org/v2/gh/baking-bad/michelson-kernel/binder?filepath=michelson_quickstart.ipynb

Option 2: run in docker

  1. Get the latest image from dockerhub (only when new releases are published)
docker pull bakingbad/michelson-kernel
  1. Create container using verified docker image:
docker run --rm -it -p 127.0.0.1:8888:8888 -v $(pwd):/home/jupyter/notebooks bakingbad/michelson-kernel
  1. Open the link from container output in your browser
  2. Save notebooks in the mapped folder in order not to loose them

Option 3: install python package

  1. Ensure you have several crypto libraries installed (see pytezos docs):
sudo apt install libsodium-dev libsecp256k1-dev libgmp-dev
  1. Install the package using pip
pip install michelson-kernel
  1. Check that Jupyter is now supporting Michelson kernel
jupyter kernelspec list

Option 4: install from sources

  1. Ensure the following packages are installed: libssl-dev zlib1g-dev uuid-dev
  2. Get the sources, build and install
git clone https://github.com/baking-bad/michelson-kernel
cd michelson-kernel
make
  1. Check that Jupyter is now supporting Michelson kernel
jupyter kernelspec list

How to uninstall

  1. Run the following command
jupyter kernelspec uninstall michelson -f
  1. Check that Jupyter is no longer supporting Michelson kernel
jupyter kernelspec list
  1. Uninstall Python package
pip uninstall michelson-kernel

How it works

Check out this introduction:
https://nbviewer.jupyter.org/github/baking-bad/michelson-kernel/blob/binder/michelson_quickstart.ipynb
Or try it in a Michelson notebook!

Acknowledgments

  • This project is supported by Tezos Foundation
  • Michelson test set from the Tezos repo is used to ensure the interpreter workability
  • Michelson structured documentation by Nomadic Labs is used for inline help

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

michelson-kernel-0.1.4.tar.gz (10.5 kB view hashes)

Uploaded Source

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