Best Way to Handle All Exceptions

Carl Banks pavlovevidence at gmail.com
Tue Jul 14 12:01:37 EDT 2009


On Jul 14, 4:48 am, Lawrence D'Oliveiro <l... at geek-
central.gen.new_zealand> wrote:
> In message <93f6a517-63d8-4c80-
>
> bf19-4614b7099... at m7g2000prd.googlegroups.com>, Carl Banks wrote:
> > Or would you rather let all unexpected exceptions print to standard
> > error, which is often a black hole in non-interactive sitations?
>
> Since when?
>
> Cron, for example, collects standard error and mails it to you.

1. Cron is only one way to run programs non-interactively. (Would that
work with, say, Windows services?)
2. Many systems don't run MTAs these days
3. In my experience the pipeline from cron to mail delivery is error
prone, mainly due to the complexity of configuring MTAs
4. Even if all this works, you might just want to do your logging
directly in Python anyway


Carl Banks



More information about the Python-list mailing list