Remove the rest references to exception.py

Remove the rest references to Oslo exception.py in Heat code base, so that Oslo
maintainer can go ahead and remove the openstack/common/exception.py file.

Change-Id: I19d325e2117f31a887c593e31b61e25729f7a053
This commit is contained in:
Liang Chen 2013-08-18 20:48:49 +08:00
parent 4c1bfe32a5
commit 1584bc17bb

View File

@ -21,14 +21,9 @@ import functools
import urlparse import urlparse
import sys import sys
from heat.openstack.common import exception
from heat.openstack.common import log as logging from heat.openstack.common import log as logging
NotFound = exception.NotFound
Error = exception.Error
InvalidContentType = exception.InvalidContentType
_FATAL_EXCEPTION_FORMAT_ERRORS = False _FATAL_EXCEPTION_FORMAT_ERRORS = False
@ -342,3 +337,16 @@ class TemplateTooBig(HeatException):
class EgressRuleNotAllowed(HeatException): class EgressRuleNotAllowed(HeatException):
message = _("Egress rules are only allowed when " message = _("Egress rules are only allowed when "
"Neutron is used and the 'VpcId' property is set.") "Neutron is used and the 'VpcId' property is set.")
class Error(Exception):
def __init__(self, message=None):
super(Error, self).__init__(message)
class NotFound(Error):
pass
class InvalidContentType(HeatException):
message = "Invalid content type %(content_type)s"