To use Kaskada, you'll need to have Python and the Kaskada Python library installed.
If you're using a Mac or Linux machine, you may already have Python installed. Verify Python is installed by opening up a terminal and running the following command:
You should see something like:
$ python --version Python 3.6
Please note: Kaskada's Python library only supports Python 3.6+.
The first step in using Kaskada in a notebook is to install the Kaskada Python client package.
pip install kaskada
Setup "fenlmagic" Extension
IPython (the Python runtime used by Jupyter) supports what it calls "magic commands" - commands prefixed with
%%, whose implementation may be provided by arbitrary Python code.
Kaskada provides a magic command to improve the Fenl authoring experience.
To use the magic extension you must first install the
fenlmagic package in your notebook environment:
pip install fenlmagic
Additional information about client installation can be found here: Reference - Client Installation
The next step is to connect to Kaskada by logging in to Kaskada's admin page and set up your environment.
We recommend using the python
getpass method to avoid saving your client id and secret to the notebook:
import os from getpass import getpass os.environ["KASKADA_CLIENT_ID"] = getpass("Enter your Kaskada Client ID here: ") os.environ["KASKADA_CLIENT_SECRET"] = getpass("Enter your Kaskada Client Secret here: ")
When executing this code-block, paste in your client id and secret, and they will be added to the environment without displaying to the screen or saving to the notebook.
After setting the environment variables, initialize the Kaskada client.
import kaskada as kda kda.init()
If your credentials are valid, this should return no results. If you get an error, check your credentials.
fenlmagic extension must be initialized to register the syntax extension with IPython:
Additional information about client authentication can be found here: Reference - Client Authentication
Updated about 1 month ago