-
Notifications
You must be signed in to change notification settings - Fork 24k
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
defined vars are empty string and not None/null #13877
Comments
no, the issue is that ansible_port is "" and not empty/None, this works:
|
Hi together, let me add my 2ct to this report: most of our playbooks are broken because of that bug. example: mydict: Here the value of mykey should be "None" and substituted by the given default. Hope this helps to fix it. cheers |
hmm, you seem to be correct:
|
So looking at this again:
outputs:
The issue with msg= is that jinja2 then translates nulls/nones into empty strings, for
outputs:
Since it is just a question of the filter interacting with the jinja2 interpolation, I'm going to close this with the above as the solution. |
This doesn't seem to work on 2.0.0.1, but it does work on 1.9.4.
Tested on Fedora 23
v1.9.4 output
v2.0.0.1 output
First posted on mailing list: https://groups.google.com/forum/#!topic/ansible-project/4JLrQVGlxZ4
Any ideas? Am I missing something?
regards
/M
The text was updated successfully, but these errors were encountered: