From 0b420cfc07bf2dc004b0c454cb52600fddc015c9 Mon Sep 17 00:00:00 2001 From: Blake Harnden <32446120+bharnden@users.noreply.github.com> Date: Tue, 19 Apr 2022 16:29:33 -0700 Subject: [PATCH] grpc: update to fix sending protobuf format wireless config for joining session --- daemon/core/api/grpc/grpcutils.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/daemon/core/api/grpc/grpcutils.py b/daemon/core/api/grpc/grpcutils.py index c6e375f9..caef470e 100644 --- a/daemon/core/api/grpc/grpcutils.py +++ b/daemon/core/api/grpc/grpcutils.py @@ -310,7 +310,18 @@ def get_node_proto( # check for wireless config wireless_config = None if isinstance(node, WirelessNode): - wireless_config = node.get_config() + configs = node.get_config() + wireless_config = {} + for config in configs.values(): + config_option = common_pb2.ConfigOption( + label=config.label, + name=config.id, + value=config.default, + type=config.type.value, + select=config.options, + group=config.group, + ) + wireless_config[config.id] = config_option # check for mobility config mobility_config = session.mobility.get_configs( node.id, config_type=Ns2ScriptedMobility.name