1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Add check to make sure dopy is at least version 0.2.2 for digital_ocean module

This commit is contained in:
Daniel Koch 2013-10-02 20:29:35 -04:00
parent 8c0e8354bf
commit cdc5e04d7b

View file

@ -160,9 +160,14 @@ import os
import time
try:
import dopy
from dopy.manager import DoError, DoManager
except ImportError as e:
print "failed=True msg='dopy required for this module'"
print "failed=True msg='dopy >= 0.2.2 required for this module'"
sys.exit(1)
if dopy.__version__ < '0.2.2':
print "failed=True msg='dopy >= 0.2.2 required for this module'"
sys.exit(1)
class TimeoutError(DoError):