From c05c2fcefdb5ed052664b3b95770f65b6b215b61 Mon Sep 17 00:00:00 2001 From: tengqm Date: Wed, 31 Dec 2014 17:51:56 +0800 Subject: [PATCH] Added two comments as TODOs It can be safely ignored if the logic is implemented somewhere else. --- senlin/db/sqlalchemy/api.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/senlin/db/sqlalchemy/api.py b/senlin/db/sqlalchemy/api.py index b09833b8c..5be61fc42 100644 --- a/senlin/db/sqlalchemy/api.py +++ b/senlin/db/sqlalchemy/api.py @@ -713,6 +713,7 @@ def action_add_depends_on(context, action_id, *actions): _('Action with id "%s" not found') % action_id) action.depends_on = list(set(actions).union(set(action.depends_on))) + # TODO(liuh): Set status to WAITING if 'depends_on' is not empty action.save(_session(context)) return action @@ -724,6 +725,7 @@ def action_del_depends_on(context, action_id, *actions): _('Action with id "%s" not found') % action_id) action.depends_on = list(set(action.depends_on).different(set(actions))) + # TODO(liuh): Set status to READY if 'depends_on' is empty action.save(_session(context)) return action