make mesh_interfaces optional

influxdb
Nils Schneider 2015-03-21 15:17:50 +01:00
parent 3ddecd26bf
commit 9195ea9650
1 changed files with 6 additions and 1 deletions

View File

@ -87,7 +87,12 @@ def import_mesh_ifs_vis_data(nodes, vis_data):
for v in mesh_nodes: for v in mesh_nodes:
node = v[0] node = v[0]
mesh_ifs = set(node['nodeinfo']['network']['mesh_interfaces'])
try:
mesh_ifs = set(node['nodeinfo']['network']['mesh_interfaces'])
except KeyError:
mesh_ifs = set()
node['nodeinfo']['network']['mesh_interfaces'] = list(mesh_ifs | v[1]) node['nodeinfo']['network']['mesh_interfaces'] = list(mesh_ifs | v[1])
def import_vis_clientcount(nodes, vis_data): def import_vis_clientcount(nodes, vis_data):