Explorar o código

Revert "Debug commit for AWS issues on Travis"

This reverts commit 489b6189445efc2cb374688510283af8b4eafedb.
Nuwan Goonasekera %!s(int64=7) %!d(string=hai) anos
pai
achega
27ad245618
Modificáronse 1 ficheiros con 7 adicións e 5 borrados
  1. 7 5
      cloudbridge/cloud/providers/aws/provider.py

+ 7 - 5
cloudbridge/cloud/providers/aws/provider.py

@@ -3,11 +3,13 @@ import logging as log
 
 import boto3
 
-# These are installed only for the case of a dev instance
-from moto import mock_ec2
-from moto import mock_s3
-
-import responses
+try:
+    # These are installed only for the case of a dev instance
+    import responses
+    from moto import mock_ec2
+    from moto import mock_s3
+except ImportError:
+    log.debug('[aws provider] moto library not available!')
 
 from cloudbridge.cloud.base import BaseCloudProvider
 from cloudbridge.cloud.base.helpers import get_env