From 9008b1f291ae38a4de9b5af5087b1815b3562e3f Mon Sep 17 00:00:00 2001 From: Vishvananda Ishaya Date: Wed, 27 Jul 2011 09:19:45 -0700 Subject: add invalid device test and make sure NovaExceptions don't get wrapped --- nova/exception.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'nova/exception.py') diff --git a/nova/exception.py b/nova/exception.py index 38e705417..ea046b712 100644 --- a/nova/exception.py +++ b/nova/exception.py @@ -116,7 +116,8 @@ def wrap_exception(notifier=None, publisher_id=None, event_type=None, notifier.notify(publisher_id, temp_type, temp_level, payload) - if not isinstance(e, Error): + if (not isinstance(e, Error) and + not isinstance(e, NovaException)): #exc_type, exc_value, exc_traceback = sys.exc_info() LOG.exception(_('Uncaught exception')) #logging.error(traceback.extract_stack(exc_traceback)) -- cgit From a0b536064620e4d18ab00c1154ec3b597ab16a67 Mon Sep 17 00:00:00 2001 From: Trey Morris Date: Wed, 27 Jul 2011 11:44:14 -0500 Subject: updated nova-manage create network. better help, handling of required args, and exceptions. Also updated FLAG flat_network_bridge to default to None --- nova/exception.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'nova/exception.py') diff --git a/nova/exception.py b/nova/exception.py index 38e705417..637cad7ee 100644 --- a/nova/exception.py +++ b/nova/exception.py @@ -372,6 +372,10 @@ class StorageRepositoryNotFound(NotFound): message = _("Cannot find SR to read/write VDI.") +class NetworkNotCreated(NovaException): + message = _("A %(req)s is required to create a network.") + + class NetworkNotFound(NotFound): message = _("Network %(network_id)s could not be found.") -- cgit From 2b0134bdfa73e7eb616414b3f8cd1b5ed99b8283 Mon Sep 17 00:00:00 2001 From: Trey Morris Date: Wed, 27 Jul 2011 13:49:36 -0500 Subject: added ipv6 requirements to nova-manage network create. changed --network to --fixed_range_v4 --- nova/exception.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nova/exception.py') diff --git a/nova/exception.py b/nova/exception.py index 637cad7ee..ca2ba3c96 100644 --- a/nova/exception.py +++ b/nova/exception.py @@ -373,7 +373,7 @@ class StorageRepositoryNotFound(NotFound): class NetworkNotCreated(NovaException): - message = _("A %(req)s is required to create a network.") + message = _("%(req)s is required to create a network.") class NetworkNotFound(NotFound): -- cgit