[tbnl-devel] Suggestion: export GET-TRACEBACK.

Edi Weitz edi at agharta.de
Tue Aug 22 15:57:55 UTC 2006


On Tue, 22 Aug 2006 10:48:28 -0400, "Erik Enge" <erik.enge at gmail.com> wrote:

> Here's the code that is invoked when an error occurs:
>
> (defun web-when-error (user dbcon request reply condition)
>   (declare (ignore dbcon reply))
>   (if (eql *sys-class* :dev)
>       (error condition)
>       (progn
>         (tbnl:log-message :error (tbnl::get-backtrace condition))
>         (case (type-of condition)
>           (db:validation-error
>            (validation-error-page user request condition))
>           (t (an-error-occurred-page user))))))
>
> Am I missing something embarrassingly obvious?

No, it looks like I just missed something in your first email.  I
think it is possible to achieve what you have now with a combination
of *HTTP-ERROR-HANDLER*, AUX-REQUEST-VALUE, and
*LOG-LISP-BACKTRACES-P*, but it'd certainly be kind of tricky.

I'll just export GET-BACKTRACE in the next release.

Cheers,
Edi.



More information about the Tbnl-devel mailing list