From 3575190ca17eb83b504401fb15dfb73679cdba55 Mon Sep 17 00:00:00 2001 From: Aaron Rosen Date: Thu, 10 Jan 2013 14:40:33 -0800 Subject: [PATCH] NvpPluginException mixes err_msg and err_desc In a few places err_msg was passed to NvpPluginException though that expected err_desc. This patch makes NvpPluginException take err_msg instead and updates err_desc to err_msg when calling NvpPluginException Fixes bug 1098351 Change-Id: I10eca5f2b98ce8faa81ad7c7687902b6f08752c1 --- quantum/plugins/nicira/nicira_nvp_plugin/QuantumPlugin.py | 2 +- quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/quantum/plugins/nicira/nicira_nvp_plugin/QuantumPlugin.py b/quantum/plugins/nicira/nicira_nvp_plugin/QuantumPlugin.py index afd06a2cd..65fcf8c97 100644 --- a/quantum/plugins/nicira/nicira_nvp_plugin/QuantumPlugin.py +++ b/quantum/plugins/nicira/nicira_nvp_plugin/QuantumPlugin.py @@ -819,7 +819,7 @@ class NvpPluginV2(db_base_plugin_v2.QuantumDbPluginV2): "in NVP for port %s") % port_data['id'] LOG.exception(err_msg) super(NvpPluginV2, self).delete_port(context, port["port"]["id"]) - raise nvp_exc.NvpPluginException(err_desc=err_msg) + raise nvp_exc.NvpPluginException(err_msg=err_msg) LOG.debug(_("create_port completed on NVP for tenant %(tenant_id)s: " "(%(id)s)"), port_data) diff --git a/quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py b/quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py index ed10c9b62..646f224e6 100644 --- a/quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py +++ b/quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py @@ -21,7 +21,7 @@ from quantum.common import exceptions as q_exc class NvpPluginException(q_exc.QuantumException): - message = _("An unexpected error occurred in the NVP Plugin:%(err_desc)s") + message = _("An unexpected error occurred in the NVP Plugin:%(err_msg)s") class NvpInvalidConnection(NvpPluginException): -- 2.45.2