diff --git a/confluent_server/confluent/discovery/core.py b/confluent_server/confluent/discovery/core.py index 8abfb017..82ba1c0b 100644 --- a/confluent_server/confluent/discovery/core.py +++ b/confluent_server/confluent/discovery/core.py @@ -684,7 +684,7 @@ def get_chained_smm_name(nodename, cfg, handler, nl=None, checkswitch=True): cd = cfg.get_node_attributes(nodename, ['hardwaremanagement.manager', 'pubkeys.tls_hardwaremanager']) smmaddr = cd[nodename]['hardwaremanagement.manager']['value'] - pkey = cd.get[nodename].get('pubkeys.tls_hardwaremanager', {}).get( + pkey = cd[nodename].get('pubkeys.tls_hardwaremanager', {}).get( 'value', None) if pkey: cv = util.TLSCertVerifier( diff --git a/confluent_server/confluent/networking/macmap.py b/confluent_server/confluent/networking/macmap.py index 67bca895..652b4dde 100644 --- a/confluent_server/confluent/networking/macmap.py +++ b/confluent_server/confluent/networking/macmap.py @@ -254,7 +254,9 @@ def find_nodeinfo_by_mac(mac, configmanager): if mac in _nodesbymac: return _nodesbymac[mac][0], {'maccount': _nodesbymac[mac][1]} # If update_mac bailed out, still check one last time - return _nodesbymac.get(mac, (None, {'maccount': 0})) + if mac in _nodesbymac: + return _nodesbymac[mac][0], {'maccount': _nodesbymac[mac][1]} + return None, {'maccount': 0} mapupdating = eventlet.semaphore.Semaphore()