substitute the result for value under 'mailhost' key of config dictionary. otherwise if klass is subclass of logging.handlers.SysLogHandler class, and string 'address' is contained in config,
elif issubclass ( klass , logging . handlers . SysLogHandler ) and 'address' in config :