From: Dan Prince Date: Mon, 25 Mar 2013 17:46:15 +0000 (-0400) Subject: Fix kwargs for NECDBException. X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=4721b5a81c43461626896ea3fc3b0ee82abe8f5d;p=openstack-build%2Fneutron-build.git Fix kwargs for NECDBException. Updates the NEC plugin to use the correct kwargs when raising NECDBException. Fixes LP Bug #1159925. Change-Id: I1e96d4ec65c1bc98d90d2eb9867fe39bbd505cdc --- diff --git a/quantum/plugins/nec/db/api.py b/quantum/plugins/nec/db/api.py index 298ecd267..a22e34d3f 100644 --- a/quantum/plugins/nec/db/api.py +++ b/quantum/plugins/nec/db/api.py @@ -113,7 +113,7 @@ def add_ofc_item(session, resource, quantum_id, ofc_id, old_style=False): session.flush() except Exception as exc: LOG.exception(exc) - raise nexc.NECDBException + raise nexc.NECDBException(reason=exc.message) return item @@ -189,7 +189,7 @@ def add_portinfo(session, id, datapath_id='', port_no=0, session.add(portinfo) except Exception as exc: LOG.exception(exc) - raise nexc.NECDBException + raise nexc.NECDBException(reason=exc.message) return portinfo