From 80dbab3cf0b319d3aa9cd7fdb8d2c7e4fd48f0c6 Mon Sep 17 00:00:00 2001 From: milan Date: Thu, 14 Mar 2013 13:06:55 +0100 Subject: [PATCH] check type of task explicitly --- lib/ansible/playbook/play.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/playbook/play.py b/lib/ansible/playbook/play.py index 73cb15e1dab..67e1c1a2173 100644 --- a/lib/ansible/playbook/play.py +++ b/lib/ansible/playbook/play.py @@ -104,6 +104,8 @@ class Play(object): tasks = [] for x in tasks: + if not isinstance(x, dict): + raise errors.AnsibleError("expecting dict; got: %s" % x) task_vars = self.vars.copy() task_vars.update(vars) if 'include' in x: