From cc134719b7cb8a0a9df76ef0d8f4343295b9d55a Mon Sep 17 00:00:00 2001 From: Marek Gradzki Date: Tue, 6 Mar 2018 12:25:02 +0100 Subject: vppapigen: require reply/details messages for requests/dumps Throw exception if details/reply is not defined instead of logger warning. Change-Id: I6eb39c51eecca6521e5f563ba09dfd62311b45ec Signed-off-by: Marek Gradzki --- src/tools/vppapigen/vppapigen.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/tools') diff --git a/src/tools/vppapigen/vppapigen.py b/src/tools/vppapigen/vppapigen.py index 628bb09def7..0779e80b7cb 100755 --- a/src/tools/vppapigen/vppapigen.py +++ b/src/tools/vppapigen/vppapigen.py @@ -608,8 +608,8 @@ class VPPAPI(object): if d[:-6] in svcs: continue if d[:-6] not in msgs: - self.logger.warning('{} missing calling message' - .format(d)) + raise ValueError('{} missing calling message' + .format(d)) continue if d.endswith('_dump'): if d in svcs: @@ -618,14 +618,14 @@ class VPPAPI(object): s['services'].append(Service(d, d[:-5]+'_details', stream=True)) else: - self.logger.error('{} missing details message' - .format(d)) + raise ValueError('{} missing details message' + .format(d)) continue if d.endswith('_details'): if d[:-8]+'_dump' not in msgs: - self.logger.error('{} missing dump message' - .format(d)) + raise ValueError('{} missing dump message' + .format(d)) continue if d in svcs: -- cgit 1.2.3-korg