misc.create_msg("Log Alert",
"☠",
args.logfile,
- "Number of errors exceeded!",
lines) )
if not error_state:
logging.warning("Entering error state!")
except Exception as e:
logging.error("Error feeding handler: %s" % str(e))
-def create_msg(title, icon, logfile, text, lines):
- msg = "<b>%s</b> <i>%s</i> %s" % (title, logfile, icon)
- msg += "<br>%s" % text
+def create_msg(title, icon, logfile, lines):
+ msg = "<b>%s</b> %s" % (title, icon)
+ msg += "<br>Too many errors in <i>%s</i>!" % logfile
msg += "<br><pre>"
for line in lines: msg += line + "\n"
msg += "</pre>"