Fix task dependency graph