<p dir="auto">The ec2.py script now creates host groups based on instance tags, but I think there might be two issues.</p>
<ol dir="auto">
<li>The order of your inventory file needs to go:</li>
</ol>
<p dir="auto">non-tag groups<br>
tag groups</p>
<p dir="auto">for the tag groups to work.  For example:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[local]
127.0.0.1

[eh_web]
x.x.x.x

[tag_Class_web]
x.x.x.x"><pre class="notranslate"><code class="notranslate">[local]
127.0.0.1

[eh_web]
x.x.x.x

[tag_Class_web]
x.x.x.x
</code></pre></div>
<p dir="auto">Is valid where x.x.x.x is a static IP.  But:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[local]
127.0.0.1

[tag_Class_web]
x.x.x.x

[eh_web]
x.x.x.x"><pre class="notranslate"><code class="notranslate">[local]
127.0.0.1

[tag_Class_web]
x.x.x.x

[eh_web]
x.x.x.x
</code></pre></div>
<p dir="auto">Only runs plays on x.x.x.x if you use the tag_Class_web group.</p>
<ol dir="auto">
<li>I'm not sure this is a bug, but I would imagine the hostgroup should be allowed to be empty in the inventory file.  Should this not work?  Neither this format nor leaving the host group out entirely causes the EC2.py script to run.</li>
</ol>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[local]
127.0.0.1

[tag_Class_web]

[eh_web]
x.x.x.x"><pre class="notranslate"><code class="notranslate">[local]
127.0.0.1

[tag_Class_web]

[eh_web]
x.x.x.x
</code></pre></div>
<p dir="auto">Since 1.4 ansible does not deduplicate hosts coming from multiple sources, which causes tasks to run multiple times on the same host in a single play.</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ tail test/* simple.yml
==&gt; test/hosts1 &lt;==
[group1]
localhost

==&gt; test/hosts2 &lt;==
[group2]
localhost

==&gt; simple.yml &lt;==
- hosts: localhost
  gather_facts: no

$ (cd ~/opt/ansible ; git checkout v1.3.4)
Previous HEAD position was 2a58c2b... Update files for 1.4 release
HEAD is now at 8e3ba1f... Version bump for 1.3.4
$ ansible --version ; ansible-playbook -i test simple.yml --list-host
ansible 1.3.4

playbook: simple.yml

  play #1 (localhost): host count=1
    localhost

$ (cd ~/opt/ansible ; git checkout v1.4.0)
Previous HEAD position was 8e3ba1f... Version bump for 1.3.4
HEAD is now at 2a58c2b... Update files for 1.4 release
$ ansible --version ; ansible-playbook -i test simple.yml --list-host
ansible 1.4

playbook: simple.yml

  play #1 (localhost): host count=2
    localhost
    localhost"><pre class="notranslate"><code class="notranslate">$ tail test/* simple.yml
==&gt; test/hosts1 &lt;==
[group1]
localhost

==&gt; test/hosts2 &lt;==
[group2]
localhost

==&gt; simple.yml &lt;==
- hosts: localhost
  gather_facts: no

$ (cd ~/opt/ansible ; git checkout v1.3.4)
Previous HEAD position was 2a58c2b... Update files for 1.4 release
HEAD is now at 8e3ba1f... Version bump for 1.3.4
$ ansible --version ; ansible-playbook -i test simple.yml --list-host
ansible 1.3.4

playbook: simple.yml

  play #1 (localhost): host count=1
    localhost

$ (cd ~/opt/ansible ; git checkout v1.4.0)
Previous HEAD position was 8e3ba1f... Version bump for 1.3.4
HEAD is now at 2a58c2b... Update files for 1.4 release
$ ansible --version ; ansible-playbook -i test simple.yml --list-host
ansible 1.4

playbook: simple.yml

  play #1 (localhost): host count=2
    localhost
    localhost
</code></pre></div>