Skip to content
Example repo for Luigi projects
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Luigi Tree

Luigi Tree is an example project based on the Luigi Python package. Once installed you can create Pascal triangle like dependency graphs using the Luigi scheduler. This project can be used as an example starting point for anyone who is working to build a command line application based on the Luigi framework.


This project was created in an effort to help anyone getting started working with Luigi. I have tried my best to make this project as "real world" as possible by using Python's setuptools for requirements and directory structure. I have also included unit tests which can be run with the following command:

python test

Check out the Luigi documentation for more code examples and use cases. I also did a blog post which goes into more detail about the usage and reasoning for this project here.


Clone luigi_tree and install it using a virtual environment:

git clone
cd luigi_tree
virtualenv /PATH/TO/VENV/luigi_tree
source /PATH/TO/VENV/luigi_tree/bin/activate
pip install .
# Optionally run the luigi server (defaults to http://localhost:8082/static/visualiser/index.html)
# Run luigi_tree with default options


usage: luigi_tree [-h] [--level LEVEL] [--sleep SLEEP]
                  [--output-dir OUTPUT_DIR] [--server SERVER] [--port PORT]

optional arguments:
  -h, --help            show this help message and exit
  --level LEVEL         Set the number of levels the tree will have, default
                        is 2
  --sleep SLEEP         Set how many seconds each task will sleep for, default
                        is 2
  --output-dir OUTPUT_DIR
                        Directory path to write output targets to, default is
  --server SERVER       Server the luigi scheduler is running on, default is
                        localhost. If there is no server running luigi_tree
                        will run using the local-scheduler
  --port PORT           Port the luigi scheduler is running on, default is
You can’t perform that action at this time.