Piotr Kliczewski has posted comments on this change. Change subject: hooks: make sure that hook error inherits from vdsm exception ......................................................................
Patch Set 4: (2 comments) https://gerrit.ovirt.org/#/c/51549/4/tests/bridgeTests.py File tests/bridgeTests.py: Line 160: Line 161: obj = json.loads(msg, 'utf-8') Line 162: mangledMethod = obj.get("method").replace(".", "_") Line 163: params = obj.get('params', []) Line 164: method = getattr(bridge, mangledMethod) > It seems that most of the code in this test is unneeded, and the same it tr Done Line 165: Line 166: with self.assertRaises(JsonRpcError) as e: Line 167: method(**params) Line 168: https://gerrit.ovirt.org/#/c/51549/4/vdsm/rpc/Bridge.py File vdsm/rpc/Bridge.py: Line 282: except TypeError as e: Line 283: self.log.exception("TypeError raised by dispatched function") Line 284: raise InvalidCall(fn, methodArgs, e) Line 285: except VdsmException as e: Line 286: raise yajsonrpc.JsonRpcError(e.code, str(e)) > We have 2 changes here - 1. Moving HooksError to vdsm.exception, 2. Support Done Line 287: Line 288: if result['status']['code']: Line 289: code = result['status']['code'] Line 290: msg = result['status']['message'] -- To view, visit https://gerrit.ovirt.org/51549 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ic9c0e953f96827737eede22ab39a1f7689c30944 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Piotr Kliczewski <[email protected]> Gerrit-Reviewer: Francesco Romani <[email protected]> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Nir Soffer <[email protected]> Gerrit-Reviewer: Piotr Kliczewski <[email protected]> Gerrit-Reviewer: Yaniv Bronhaim <[email protected]> Gerrit-Reviewer: gerrit-hooks <[email protected]> Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
