elif software == "":
raise ValueError("Parameter 'software' is empty")
elif software in _cache["alias"]:
- logger.debug("Returning cached value='%s' for function 'alias' - EXIT!", _cache["alias"][software])
+ logger.debug("Returning cached alias='%s' - EXIT!", _cache["alias"][software])
return _cache["alias"][software]
key = software
def strip_powered_by(software: str) -> str:
logger.debug("software='%s' - CALLED!", software)
+
if not isinstance(software, str):
raise ValueError(f"Parameter software[]='{type(software)}' is not of type 'str'")
elif software == "":
def is_relay(software: str) -> bool:
logger.debug("software='%s'- CALLED!", software)
- if not isinstance(software, str) and software is not None:
+ if not isinstance(software, str):
raise ValueError(f"software[]='{type(software)}' is not type 'str'")
+ elif software == "":
+ raise ValueError("Parameter 'software' is empty")
found = software in relays