diff options
author | James Cammarata <jimi@sngx.net> | 2016-05-11 21:49:46 -0400 |
---|---|---|
committer | James Cammarata <jimi@sngx.net> | 2016-05-11 21:50:51 -0400 |
commit | af257c20dad388f66b238f6c34668e3ec82f2220 (patch) | |
tree | 73daca9c29f5fdb98eaf29c2ae89adf07876dba8 | |
parent | 0040c6a4d2df047a60422965be6ebd9fbb9b55cf (diff) | |
download | ansible-af257c20dad388f66b238f6c34668e3ec82f2220.tar.gz |
Change error about loop variable in use to a warning
-rw-r--r-- | lib/ansible/executor/task_executor.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ansible/executor/task_executor.py b/lib/ansible/executor/task_executor.py index 2a475c2a10..ec220dd7c9 100644 --- a/lib/ansible/executor/task_executor.py +++ b/lib/ansible/executor/task_executor.py @@ -232,7 +232,7 @@ class TaskExecutor: loop_var = self._task.loop_control.loop_var or 'item' if loop_var in task_vars: - raise AnsibleError("the loop variable '%s' is already in use. You should set the `loop_var` value in the `loop_control` option for the task to something else to avoid variable collisions" % loop_var) + display.warning("The loop variable '%s' is already in use. You should set the `loop_var` value in the `loop_control` option for the task to something else to avoid variable collisions and unexpected behavior." % loop_var) items = self._squash_items(items, loop_var, task_vars) for item in items: |