Argument group is of type 'dict' and we were unable to convert to list
<p>I'm trying to break some commonly-done AWS tasks into roles so that I can use them more nimbly in playbooks and have hit an unexpected roadblock. I can't figure this one out:</p>

<p>This play works just fine directly with 'group' defined as a list directly in the task:</p>

<pre><code>ec2:
 image: "{{image}}"
 region: "{{region}}"
 group: [ "ssh", "outbound" ]
 [... other stuff]
</code></pre>

<p>But Ansible fails if I instead put the play in a role and define 'groups' in its 'defaults/main.yml' file like this: </p>

<pre><code>groups: ["ssh", "outbound"]
</code></pre>

<p>The play now looks like this:</p>

<pre><code>ec2:
 image: "{{image}}"
 region: "{{region}}"
 group: "{{groups}}"
 [... other stuff]
</code></pre>

<p>Ansible fails with this message, seeming to think my variable is a dict, not a list:</p>

<pre><code>fatal: [localhost]: FAILED! =&gt; {"changed": false, "failed": true, "msg": "argument group is of type &lt;type 'dict'&gt; and we were unable to convert to list"}
</code></pre>

<p>I'm either missing something obvious or have run into a limitation of Ansible's variable parsing. Anyone have any insight into this?</p>