>
> ((ansible_eth1|default({})["ipv4"]|default({}))["address"] |
> default("127.0.0.1")
>
Ugh. I was expecting something like try: ... except KeyError: ...
Is there any chance of fixing default to work with multiple levels without
so much typing? I think it would be a rather big usability improvement.
Cheers,
Paul
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/51c31f67-be57-4b97-845c-256465f9f573%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.