Commands Cheat Sheet

Evaluating engineering tools? Get the comparison in Google Sheets

(Perfect for making buy/build decisions or internal reviews.)

Most-used commands
Your email is safe thing.

Thankyou for your submission

We have sent the cheatsheet on your email!
Oops! Something went wrong while submitting the form.

Getting Started

metaflow tutorials
Start Metaflow tutorials to learn about its capabilities

python -m metaflow.tutorials
Alternative way to start the tutorials

metaflow tutorials pull
Download tutorials to your machine

Flow Management

python flow.py run
Run a Metaflow flow

python flow.py --environment=conda run
Run a flow with Conda environment

python flow.py --with kubernetes run
Run a flow on Kubernetes

python flow.py --with batch run
Run a flow on AWS Batch

python flow.py resume
Resume a previously failed run

Flow Operations

python flow.py show
Show details of the latest run

python flow.py status
Show status of the latest run

python flow.py card
View cards from the latest run

python flow.py step-functions create
Create AWS Step Functions

Inspecting Results

from metaflow import Flow
Import Flow class for inspecting results in Python

flow = Flow('FlowName')
Access a specific flow in Python

run = flow.latest_run
Access the latest run in Python

run = flow['run_id']
Access a specific run in Python

run.data
Access the data artifact from the final step

Debugging

python flow.py --debug run
Run a flow in debug mode

python flow.py step-functions create --only-json
Export step functions as JSON

Environment Management

python flow.py --with conda run
Run with conda environment

python flow.py --with kubernetes run
Run on Kubernetes

python flow.py --max-workers N run
Run with N parallel workers

Deployment

python flow.py --production run
Run in production mode

python flow.py --tag tag1,tag2 run
Add tags to the run

metaflow configure aws
Configure AWS credentials for Metaflow