Thanks Brian,
If people find the filter useful then that's fair enough. Everybody has a
difference preference. I probably suffer from Python's "There should be one
-- and preferably only one -- obvious way to do it."
On Thu, Apr 12, 2018 at 9:25 PM, Brian Coca wrote:
> Other people found it co
Other people found it confusing and wanted something they could easily
lookup up, like a filter.
Once I added it, I stopped hearing complaints, so not sure how much
that is worth other than anecdotal evidence.
Use whichever way suits you best.
--
--
Brian Coca
--
You received this
On Wednesday, April 11, 2018 at 3:10:34 PM UTC+1, Brian Coca wrote:
>
>
> The `ternary` filter is easier for people that are not familiar with
> Python, but non programmers and those used to ternary structures in
> other languages.
>
>
I'm used to the different ternary structures from differen
Even though Ansible is written in Python, Python devs are not the main
target of the tool, so being 'pythonic' is not really an aim of it.
The `ternary` filter is easier for people that are not familiar with
Python, but non programmers and those used to ternary structures in
other languages.
--
I've been recently wondering about the ternary filter in Ansible. I've seen
it used in a couple of places and it's also mentioned in the documentation.
As you probably know, it's not a standard Jinja filter but one created in
Ansible code.
I would like to understand why was the ternary filte