Add return messages on boto library load failure

lines for library not avalible and wrong version added.
This commit is contained in:
michael guldan 2015-12-03 16:07:19 -08:00
parent f5e24872f1
commit b53da0eb4b

View File

@ -81,9 +81,9 @@ def __virtual__():
# which was added in boto 2.8.0
# https://github.com/boto/boto/commit/33ac26b416fbb48a60602542b4ce15dcc7029f12
if not HAS_BOTO:
return False
return (False, "The boto_ec2 module cannot be loaded: boto library not found")
elif _LooseVersion(boto.__version__) < _LooseVersion(required_boto_version):
return False
return (False, "The boto_ec2 module cannot be loaded: boto library verion incorrect ")
return True