X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=resources%2Flibraries%2Fpython%2FVppCounters.py;h=c115efcdb515df31187718b5a2c0ad99b708eed8;hb=20cc67d5f23a7f4e05b08012bf3d3a63be4bcf63;hp=65d647709d1b6dd7eb474a96f95b366368b7098d;hpb=c4528bcd137c0813d34b1b248bc92670736e78e6;p=csit.git diff --git a/resources/libraries/python/VppCounters.py b/resources/libraries/python/VppCounters.py index 65d647709d..c115efcdb5 100644 --- a/resources/libraries/python/VppCounters.py +++ b/resources/libraries/python/VppCounters.py @@ -71,7 +71,7 @@ class VppCounters(object): return runtime = [] - runtime_non_zero = [] + runtime_nz = [] for name in names: runtime.append({'name': name}) @@ -100,18 +100,20 @@ class VppCounters(object): if (sum(calls_th) or sum(vectors_th) or sum(suspends_th) or sum(clocks_th)): - runtime_non_zero.append(runtime_item) + runtime_nz.append(runtime_item) if log_zeros: logger.info( - "stats runtime ({host} - {socket}):\n{runtime}".format( - host=node['host'], runtime=pformat(runtime), - socket=socket)) + "stats runtime ({host} - {socket}):\n{runtime}". + format( + host=node['host'], runtime=pformat(runtime), + socket=socket)) else: logger.info( - "stats runtime ({host} - {socket}):\n{runtime}".format( - host=node['host'], runtime=pformat(runtime_non_zero), - socket=socket)) + "stats runtime ({host} - {socket}):\n{runtime}". + format( + host=node['host'], runtime=pformat(runtime_nz), + socket=socket)) @staticmethod def vpp_show_runtime_counters_on_all_duts(nodes):