From: Aaron Rosen Date: Thu, 10 Jan 2013 22:40:33 +0000 (-0800) Subject: NvpPluginException mixes err_msg and err_desc X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=3575190ca17eb83b504401fb15dfb73679cdba55;p=openstack-build%2Fneutron-build.git 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 --- 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):