]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
NvpPluginException mixes err_msg and err_desc
authorAaron Rosen <arosen@nicira.com>
Thu, 10 Jan 2013 22:40:33 +0000 (14:40 -0800)
committerAaron Rosen <arosen@nicira.com>
Fri, 11 Jan 2013 21:03:26 +0000 (13:03 -0800)
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
quantum/plugins/nicira/nicira_nvp_plugin/common/exceptions.py

index afd06a2cda7117f70f0e895dc0fdcc5ffd225278..65fcf8c97993f7eafc72b410aa8ef6d2c3303c83 100644 (file)
@@ -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)
index ed10c9b621052190ba491b835f3c7ee642c12462..646f224e677c97c978dc28025062e7d035b7165c 100644 (file)
@@ -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):