Fix task dependency graph

Fixes #60