In Ansible Expect Module, how to ignore warning text showing before responding to prompts?
<p>thanks to the reply provided to my <a href="https://stackoverflow.com/questions/38264206/how-to-process-a-command-asking-for-inputs-with-an-ansible-task/38267574#38267574">question</a>, I learned about the Expect module. In my Ansible playbook, I use it to execute a command and to respond to prompts.  My issue now is that my <code>command</code> returns to stdout a warning text before prompting for username, email and password. The expect task then fails, I guess because it does not now what to do with this line of text.</p>

<p>My <strong>playbook.yml</strong></p>

<pre><code>  - expect:
        command: geonode createsuperuser
        responses:
          username: 'test'
          email: 'test@whatever.com'
          password: 'test'
</code></pre>

<p>The failure report:</p>

<pre><code>TASK [expect] ******************************************************************
fatal: [node1]: FAILED! =&gt; {"changed": true, "cmd": "geonode createsuperuser", "delta": "0:00:30.129827", "end": "2016-07-28 09:39:57.806523", "failed": true, "rc": null, "start": "2016-07-28 09:39:27.676696", "stdout": "Not enabling BingMaps base layer as a BING_API_KEY is not defined in local_settings.py file.\r\nUsername: ", "stdout_lines": ["Not enabling BingMaps base layer as a BING_API_KEY is not defined in local_settings.py file.", "Username: "]}
</code></pre>

<p>Unfortunately I can't disable the warning at this stage of the configuration.</p>

<p>Thank you for any help you can provide.</p>