From 0f4940cd7c22537cdea36d984380914aa350a349 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 16 Jan 2018 13:14:13 -0500 Subject: [PATCH] Tolerate empty string to be blank snmp user For SNMP password without user, accept '' as a synonym for None --- confluent_server/confluent/networking/netutil.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/confluent_server/confluent/networking/netutil.py b/confluent_server/confluent/networking/netutil.py index fb140ef2..60106c34 100644 --- a/confluent_server/confluent/networking/netutil.py +++ b/confluent_server/confluent/networking/netutil.py @@ -34,6 +34,8 @@ def get_switchcreds(configmanager, switches): 'public') user = switchparms.get( 'secret.hardwaremanagementuser', {}).get('value', None) + if not user: + user = None switchauth.append((switch, password, user)) return switchauth