From 3691bd34143ff6e725c3be5cfee7d2539f84169f Mon Sep 17 00:00:00 2001 From: Jan Gelety Date: Thu, 3 Oct 2019 19:42:34 +0200 Subject: [PATCH] FIX: use int of sw_if_index in call of sw_interface_set_flags api - it will avoid situation that corresponding port is not up and its sw_if_index value in topology file is None that is interpreted as 0 in vpp api so it set flag for local0 interface Change-Id: I9145077d787ddde50a29bcd4091035e95077f946 Signed-off-by: Jan Gelety --- resources/libraries/python/InterfaceUtil.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/libraries/python/InterfaceUtil.py b/resources/libraries/python/InterfaceUtil.py index b25e70bd6e..1d1d669556 100644 --- a/resources/libraries/python/InterfaceUtil.py +++ b/resources/libraries/python/InterfaceUtil.py @@ -193,7 +193,7 @@ class InterfaceUtil(object): err_msg = 'Failed to set interface state on host {host}'.format( host=node['host']) args = dict( - sw_if_index=sw_if_index, + sw_if_index=int(sw_if_index), flags=flags) with PapiSocketExecutor(node) as papi_exec: papi_exec.add(cmd, **args).get_reply(err_msg) -- 2.16.6