Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Changeset 1021

Show
Ignore:
Timestamp:
03/29/06 00:24:49
Author:
fumanchu
Message:

Fix for the fix for #486 (hey, that rhymes!).

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/cherrypy/_cputil.py

    r1020 r1021  
    324324    if exc == (None, None, None): 
    325325        return "" 
    326     if hasattr(exc[1], "args"): 
    327         page_handler_str = "" 
    328         if len(exc[1].args) > 1: 
    329             page_handler = exc[1].args.pop() 
     326     
     327    page_handler_str = "" 
     328    args = list(getattr(exc[1], "args", [])) 
     329    if args: 
     330        if len(args) > 1: 
     331            page_handler = args.pop() 
    330332            page_handler_str = 'Page handler: %s\n' % repr(page_handler) 
     333            exc[1].args = tuple(args) 
    331334    return page_handler_str + "".join(traceback.format_exception(*exc)) 
    332335 

Hosted by WebFaction

Log in as guest/cpguest to create tickets