# Ansible is capable of many things

**URL:** <https://forum.ansible.com/t/ansible-is-capable-of-many-things/45931>\
**Category:** Project Discussions\
**Tags:** galaxy-ng, ansible-core\
**Created:** [June 17, 2026, 7:57am UTC](https://forum.ansible.com/t/ansible-is-capable-of-many-things/45931 "2026-06-17T07:57:51Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![utoddl](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/utoddl/32/249_2.png) [@utoddl](https://forum.ansible.com/u/utoddl)\
**Post date:** [June 17, 2026, 3:07pm UTC](https://forum.ansible.com/t/ansible-is-capable-of-many-things/45931/6 "2026-06-17T15:07:08Z")

</div>

Oh, right: dict (i.e. order doesn’t matter) in the `capable.core212.logical` filter vs. list items (order does matter) in the `utoddl.logical.logical` filter. I glided right over that difference and didn’t even notice on first reading. Oops.

Also, naming things is hard™. I had a working stand alone `logical` filter before collections were a thing, then leaped - perhaps prematurely - onto the collection bandwagon as soon as that became practical. I ended up with a collection with a stupid name containing only the one filter of the same name. Similarly, I suspect “`core212`” as a component in your FQCN is going to be of dwindling interest rather soon. But I guess that’s partly the point.

I will say this: Your code is _way cleaner_ than mine, and that’s only partly because mine includes data promotions. Mine is also about ⅓ debugging print statements. There’s a reason my code looks like it was written by somebody who learned BASIC in the late '70s and hadn’t really grokked Python when he started writing Ansible filters. But since it works and life is short enough already, I haven’t prioritized cleaning it up.

To @jon-nfc’s point, which paraphrased is, “Why embed logic in data outside of the Jinja provided methods?” @kks already mentioned Jinja is geared toward text, although Ansible is much smarter about interpreting Jinja output as data than it was at the time `utoddl.logical.logical` (ne `logical`) was written. Likewise the number and quality of Ansible filters etc has vastly improved since then. Even so, for me it comes down to, “Which expression of the data and logic would I rather maintain?”

If anyone finds `logical` (any variant) abhorrent, then by all means don’t use it. But for those intrigued by the idea of data altering itself, then I invite you to take a look at the [`polymac`](https://forum.ansible.com/t/polymac-filter-for-ansible/36123) filter!

---

_[View the full topic](https://forum.ansible.com/t/ansible-is-capable-of-many-things/45931)._
