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

Changeset 150

Show
Ignore:
Timestamp:
02/13/05 09:28:49
Author:
rdelon
Message:

Fixed test for filter.
Fixed default _cpOnError to use a list fo cpg.response.body

Files:

Legend:

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

    r116 r150  
    6161    bodyFile = StringIO.StringIO() 
    6262    traceback.print_exc(file = bodyFile) 
    63     cpg.response.body = bodyFile.getvalue() 
     63    cpg.response.body = [bodyFile.getvalue()] 
    6464    cpg.response.headerMap['Content-Type'] = 'text/plain' 
    6565 
  • trunk/cherrypy/_cphttptools.py

    r145 r150  
    214214        # error reporting seems to be broken in some cases. This code is  
    215215        # a helper to check it 
    216         print "%"*80 
    217216        traceback.print_exc() 
    218         print "%"*80 
    219217        err = "" 
    220218        exc_info_1 = sys.exc_info()[1] 
     
    250248                wfile.write(line) 
    251249        except: 
    252             # TODO: in some cases exceptions and filters are conflicting;  
    253             # error reporting seems to be broken in some cases. This code is  
    254             # a helper to check it 
    255             #print "%"*80 
    256             #traceback.print_exc() 
    257             #print "%"*80 
    258250            bodyFile = StringIO.StringIO() 
    259251            traceback.print_exc(file = bodyFile) 
     
    408400    cpg.request.objectPath = '/' + '/'.join(objectPathList[1:]) 
    409401    body = func(*(virtualPathList + cpg.request.paramList), **(cpg.request.paramMap)) 
    410      
     402 
    411403    # builds a uniform return type 
    412404    if not isinstance(body, types.GeneratorType): 
  • trunk/cherrypy/test/helper.py

    r110 r150  
    122122    def all(self): 
    123123        cpg.server.stop() 
     124        return "" 
    124125    all.exposed = True 
    125126cpg.root.shutdown = Shutdown() 

Hosted by WebFaction

Log in as guest/cpguest to create tickets