From 53b9a13a515c7e09d2b888ea416f3bd3890d8c16 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 28 Aug 2024 19:18:43 -0400 Subject: [PATCH] Fix different invocations of check_fish Particularly nodediscover register can fail. Those invocations are XCC specific, so the targtype should not matter in those cases. --- confluent_server/confluent/discovery/protocols/ssdp.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/confluent_server/confluent/discovery/protocols/ssdp.py b/confluent_server/confluent/discovery/protocols/ssdp.py index c7063838..5c27473b 100644 --- a/confluent_server/confluent/discovery/protocols/ssdp.py +++ b/confluent_server/confluent/discovery/protocols/ssdp.py @@ -451,7 +451,11 @@ def _find_service(service, target): def check_fish(urldata, port=443, verifycallback=None): if not verifycallback: verifycallback = lambda x: True - url, data, targtype = urldata + try: + url, data, targtype = urldata + except ValueError: + url, data = urldata + targtype = 'service:redfish-bmc' try: wc = webclient.SecureHTTPConnection(_get_svrip(data), port, verifycallback=verifycallback, timeout=1.5) peerinfo = wc.grab_json_response(url, headers={'Accept': 'application/json'})