diff options
-rw-r--r-- | lib/ansible/modules/utilities/logic/wait_for.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/ansible/modules/utilities/logic/wait_for.py b/lib/ansible/modules/utilities/logic/wait_for.py index 7d9b047146..2380c36be8 100644 --- a/lib/ansible/modules/utilities/logic/wait_for.py +++ b/lib/ansible/modules/utilities/logic/wait_for.py @@ -161,6 +161,7 @@ EXAMPLES = ''' import binascii import datetime import math +import os import re import select import socket @@ -177,6 +178,13 @@ try: except ImportError: pass +#fix for python <2.4 compatibility +if sys.version_info[0] < 3 and sys.version_info[1] < 5: + def any(iterable): + for element in iterable: + if element: + return True + return False class TCPConnectionInfo(object): """ |