RE: Exception report library

From: Robert Brewer (fumanchu_at_amor.org)
Date: 01/07/05


Date: Fri, 7 Jan 2005 13:37:07 -0800
To: "Ian Bicking" <ianb@colorstudy.com>, <python-list@python.org>

Ian Bicking wrote:
> I've been using one of several systems to catch unexpected exceptions
> and log them (e.g., write to a file, display on web page, email me,
> etc). But many are built into a particular system, or have an
> interesting but incomplete set of features. E.g., many web
> frameworks have exception reporters (and the stdlib includes cgitb),
> but I want to handle non-web exceptions in the same way as exceptions
> from web requests, and that's not generally easy.
...
> I feel like there must be something out there, since every Python
> programmer has to deal with this sort of thing to some degree...?

I feel that way, too, but haven't found it. I broke my webapp framework
out of my ORM late last year, and quickly realized how small the core
framework really is (22k, versus 250k for the web bits). Features like
the logging handler could be provided as separate modules, rather than
built into the Application object, and I've been meaning to get around
to that. If we could put our many heads together, I think this would be
doable for the stdlib.

Here are the pieces of the framework, by the way, which might also
benefit from some standardization (I was thinking about them all at
once):

   1. Thread-safe application state
   2. Logging (+ exception handling)
   3. Configuration data (reading from various sources)
   4. Registry of Workers for getting things done on a schedule,
possibly recurring
   5. Registry of startup/shutdown functions
   6. Registry of active user interfaces

I think the first three are all good candidates for a standard. If we
had a standard, thread-safe Application object, the rest could be
registerable plugins for that. You'd basically register callbacks for
app.startup and .shutdown methods to iterate over.

Robert Brewer
MIS
Amor Ministries
fumanchu@amor.org



Relevant Pages

  • Re: Where are ALL of the firewall.cpl parameters stored?
    ... > term used to refer to the setting, along with the name of the registry ... > Allow local program exceptions AllowUserPrefMerge ... > Allow remote desktop exception RemoteDesktop ... > Logfile pathname LogFilePath ...
    (microsoft.public.windowsxp.security_admin)
  • Re: Dateitypen und Executables - wie Zuordnung feststellen?
    ... > Natürlich können da eine ganze Menge Exceptions (z.B. ... > NullReferenceException) auftreten, wenn was in der Registry nicht ... In meiner Registry haben weder "doc" ... mal Herfrieds Weg über PInvoke anschauen. ...
    (microsoft.public.de.german.entwickler.dotnet.framework)
  • PPC URLNetwork exceptions registry
    ... exceptions to the Proxy settings in the registry? ... We have over 500 PPC 2003 devices and this would be good if we could ... import these via the registry. ...
    (microsoft.public.pocketpc.developer)
  • Re: semantics of loating point exception handling
    ... >>sometimes I need to have proper control of the floating point arithmetic of ... >>C99 standard is quite handy for that purpose. ... > exceptions raised by preceding code, so it must be a synchronising operation. ... >floating-point exceptions represented by the argument excepts. ...
    (comp.lang.c)
  • Re: BizTalk customized error logging
    ... exception catches but I can't run it under BizTalk. ... > I have used a custom pipeline component to provide "recovery" from Xml ... > catches exceptions. ... > Alternatively, use BTS2006, where this functionality is standard. ...
    (microsoft.public.biztalk.general)