logging, can one get it to email messages over a certain level?

Steve Howell showell30 at yahoo.com
Sun Nov 11 18:56:46 CET 2012

On Nov 11, 9:48 am, tinn... at isbd.co.uk wrote:
> I'm sure this must be possible but at the moment I can't see how to do it.
> I want to send an E-Mail when the logging module logs a message above
> a certain level (probably for ERROR and CRITICAL messages only).
> I.e. I want some sort of hook that will be called when these messages
> are logged (I can do the sendmail bit OK, I've got code that does that).
> --
> Chris Green

Scroll down to the Handlers section here:


I'm not sure this explains perfectly what you're gonna need to do, but
I hope it gets you in the ballpark.

More information about the Python-list mailing list