community.general/lib/ansible/modules/utilities/logic
sethp-nr 402b095841 wait_for: treat broken connections as "unready" (#28839)
* wait_for: treat broken connections as "unready"

We have observed the following condition while waiting for hosts:

```
Traceback (most recent call last):
  File "/var/folders/f8/23xp00654plcv2b2tcc028680000gn/T/ansible_8hxm4_/ansible_module_wait_for.py", line 585, in <module>
    main()
  File "/var/folders/f8/23xp00654plcv2b2tcc028680000gn/T/ansible_8hxm4_/ansible_module_wait_for.py", line 535, in main
    s.shutdown(socket.SHUT_RDWR)
  File "/usr/local/opt/python/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py", line 228, in meth
    return getattr(self._sock,name)(*args)
socket.error: [Errno 57] Socket is not connected
```

This appears to happen while the host is still starting; we believe something is
accepting our connection but immediately resetting it. In these cases, we'd
prefer to continue waiting instead of immediately failing the play.

This patch has been applied locally for some time, and we have seen no adverse
effects.

* wait_for: fixup change

We were missing an import and a space after the `#`
2017-10-12 11:37:20 -04:00
..
__init__.py
_include.py corrected import_play into to import_playbook (#30853) 2017-09-26 17:27:21 -04:00
assert.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
async_status.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
async_wrapper.py utilities modules: PEP8 compliancy (#27741) 2017-08-10 09:36:28 +01:00
debug.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
fail.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
import_playbook.py corrected import_play into to import_playbook (#30853) 2017-09-26 17:27:21 -04:00
import_role.py clarify documentation of import_role 2017-09-18 16:17:58 -04:00
import_tasks.py Remove stray " and replace include: with import_tasks: 2017-09-27 10:02:43 -04:00
include_role.py deprecated include 2017-09-15 13:20:32 -07:00
include_tasks.py deprecated include 2017-09-15 13:20:32 -07:00
include_vars.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
pause.py minor doc change to use module ref in rst 2017-08-30 11:16:27 -04:00
set_fact.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
set_stats.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00
wait_for.py wait_for: treat broken connections as "unready" (#28839) 2017-10-12 11:37:20 -04:00
wait_for_connection.py Update metadata to 1.1 2017-08-15 23:12:08 -07:00