[cl-weblocks-ticket] Re: #6: Handling and reporting errors

cl-weblocks cl-weblocks-devel at common-lisp.net
Tue Mar 18 18:06:52 UTC 2008


#6: Handling and reporting errors
--------------------------+-------------------------------------------------
  Reporter:  sakhmechet   |       Owner:  sakhmechet            
      Type:  enhancement  |      Status:  new                   
  Priority:  medium       |   Milestone:  0.2                   
 Component:  weblocks     |     Version:  pre-0.1               
Resolution:               |    Keywords:  error handling failure
--------------------------+-------------------------------------------------
Comment (by sakhmechet):

 Ok, the following four aspects need to be worked out:

 1. A customized error page on regular requests in release mode.
 2. Properly presenting errors and stack traces on AJAX requests in debug
 mode (instead of session timeout popup).
 3. Properly presenting errors on AJAX requests in release mode (perhaps
 "an error occurred" popup is sufficient).
 4. Dealing with true session timeout errors.

 The first aspect can be solved via hunchentoot's *http-error-handler*.
 Perhaps weblocks should provide a wrapper interface for this.

 The second aspect can be solved by dumping a full stack trace to the pop
 up box. This will involve informing the JS frontend whether we're in
 release or debug mode. I'm not completely sure how to do that. Perhaps
 include an extra debug-weblocks.js file on release mode?

 The third aspect pretty much works as intended today. I'm not sure if
 anything needs to be done here, perhaps an automatic refresh once the user
 hits "OK" in the JS popup?

 The fourth aspect (actual session timeouts) seems fairly easy to handle.
 Instead of signalling a simple-error (like weblocks does today in request-
 handler.lisp:43), it can signal a special condition (session-timeout,
 etc.). The default handler can simply redirect to the root URL '/', while
 a customized handler can take a different action (redirect to another URL,
 etc).

 What do you think?

-- 
Ticket URL: <http://trac.common-lisp.net/cl-weblocks/ticket/6>
cl-weblocks <http://common-lisp.net/project/cl-weblocks>
cl-weblocks


More information about the Cl-weblocks-ticket mailing list