-
Notifications
You must be signed in to change notification settings - Fork 162
Description
Description
Especially given the lack of documentation, children: in the YAML frontend is an opaque implementation detail. The Python API takes Group(actions=...) so I believe so should YAML.
Motivation
More intuitive usage for YAML
Design / Implementation Considerations
The children: special key is an implementation detail that is not present in XML because of its structure.
<group if="condition">
<child />
</group>In YAML the various lists of items that would go into the XML tag body are instead implemented as keys. The catch-all key is children:
group:
if: condition
children:
- child:In some other cases the children may be heterogenous attribute lists instead of Actions, so those are always implemented with an explicit name,
<node>
<param name="x" value="y" />
</node>- node:
param:
- name: x
value: yI think it's fine to continue to have children: as the fallback, especially to not break existing usage, but adding an additional option for actions: to match the Python API makes a lot of sense. This would apply to any other Actions that take child actions (as noted, attributes must always be explicitly named so that's not a problem), if there are any
Additional Information
No response