summaryrefslogtreecommitdiffstats
path: root/openstack
diff options
context:
space:
mode:
authorRussell Bryant <rbryant@redhat.com>2012-05-02 09:41:10 -0400
committerRussell Bryant <rbryant@redhat.com>2012-05-02 09:41:10 -0400
commitdc6ec67c5c06d411e06e03d393bac863399a67b6 (patch)
treedee5734bbd80ed6724b758ec1a8a641bfd100a25 /openstack
parentc421e79d6b04f307e6dba3a9916fcf5e3c4630ff (diff)
downloadoslo-dc6ec67c5c06d411e06e03d393bac863399a67b6.tar.gz
oslo-dc6ec67c5c06d411e06e03d393bac863399a67b6.tar.xz
oslo-dc6ec67c5c06d411e06e03d393bac863399a67b6.zip
Remove common.exception from common.importutils.
This patch removes the usage of common.exception from common.importutils. Instead of raising exception.NotFound() from importutils.import_class(), just use the built-in ImportError. Change-Id: I95e84908d1f80c5ca3bbac049eda8faa64212ae0
Diffstat (limited to 'openstack')
-rw-r--r--openstack/common/importutils.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/openstack/common/importutils.py b/openstack/common/importutils.py
index 48b7af1..7654af5 100644
--- a/openstack/common/importutils.py
+++ b/openstack/common/importutils.py
@@ -21,8 +21,6 @@ Import related utilities and helper functions.
import sys
-from openstack.common import exception
-
def import_class(import_str):
"""Returns a class from a string including module and class"""
@@ -31,7 +29,7 @@ def import_class(import_str):
__import__(mod_str)
return getattr(sys.modules[mod_str], class_str)
except (ImportError, ValueError, AttributeError), exc:
- raise exception.NotFound('Class %s cannot be found (%s)' %
+ raise ImportError('Class %s cannot be found (%s)' %
(class_str, str(exc)))