Use EntityNotFound instead of NovaNetworkNotFound.
replace and remove NovaNetworkNotFound Change-Id: Iaf8fa96ebd68c305ac2ec7565ff54d7b43c45a09 Partial-Bug: #1515603
This commit is contained in:
@@ -23,7 +23,7 @@ from heat.engine import constraints
|
||||
class NetworkConstraint(constraints.BaseCustomConstraint):
|
||||
|
||||
expected_exceptions = (exceptions.NeutronClientException,
|
||||
exception.NovaNetworkNotFound,
|
||||
exception.EntityNotFound,
|
||||
exception.PhysicalResourceNameAmbiguity)
|
||||
|
||||
def validate_with_client(self, client, value):
|
||||
|
||||
@@ -573,7 +573,7 @@ echo -e '%s\tALL=(ALL)\tNOPASSWD: ALL' >> /etc/sudoers
|
||||
except exceptions.NotFound as ex:
|
||||
LOG.debug('Nova network (%(net)s) not found: %(ex)s',
|
||||
{'net': label, 'ex': ex})
|
||||
raise exception.NovaNetworkNotFound(network=label)
|
||||
raise exception.EntityNotFound(entity='Nova network', name=label)
|
||||
except exceptions.NoUniqueMatch as exc:
|
||||
LOG.debug('Nova network (%(net)s) is not unique matched: %(exc)s',
|
||||
{'net': label, 'exc': exc})
|
||||
@@ -692,7 +692,7 @@ class FlavorConstraint(constraints.BaseCustomConstraint):
|
||||
|
||||
class NetworkConstraint(constraints.BaseCustomConstraint):
|
||||
|
||||
expected_exceptions = (exception.NovaNetworkNotFound,
|
||||
expected_exceptions = (exception.EntityNotFound,
|
||||
exception.PhysicalResourceNameAmbiguity)
|
||||
|
||||
def validate_with_client(self, client, network):
|
||||
|
||||
Reference in New Issue
Block a user