New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
when conditional is ignored if with_items contains undefined value #13791
Comments
Possible MisunderstandingHi! Thanks very much for your submission to Ansible. It sincerely means a lot to us. We believe the ticket you have filed is being somewhat misunderstood, as one thing works a little differently than stated.
In the future, this might be a topic more well suited for the user list, which you can also post here if you'd like some more help with the above. Thank you once again for this and your interest in Ansible! |
Issues were listed here: ansible/ansible#14383 and here: ansible/ansible#13791 But at the end, it's normal ansible behaviour and ansible 1.9 was too kind with that. This should avoid all the problems.
Issue Type:
Bug Report
Ansible Version:
Environment:
Ubuntu 14.04
Summary:
A task's
with_items
seem to be evaluated before itswhen
clause.If a variable used within an item is undefined, the task will fail even if the when clause says it should only run when that same variable is defined.
Steps To Reproduce:
Expected Results:
Task is skipped since
test_src
is undefinedWorked as expected in Ansible 1.9.4
Actual Results:
The text was updated successfully, but these errors were encountered: