Commit 6b836c91 authored by Dmitry Lukhtionov's avatar Dmitry Lukhtionov
Browse files

Fix DCN.DCWL.get_metrics script

parent 07ed285a
......@@ -120,6 +120,8 @@ class Script(GetMetricsScript):
"tx-errors": "Interface | Errors | Out"}
c = self.cli("get interface all detail")
for block in c.split("\n\n"):
if not block:
continue
ifaces += [dict(line.split(None, 1) for line in block.splitlines()
if len(line.split(None, 1)) == 2)]
self.get_beacon_iface(ifaces)
......@@ -159,6 +161,8 @@ class Script(GetMetricsScript):
r_metrics = defaultdict(dict)
w = self.cli("get radio all detail")
for block in w.split("\n\n"):
if not block:
continue
data = dict(line.split(None, 1) for line in block.splitlines()
if len(line.split(None, 1)) == 2)
iface = data["name"].strip()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment