Changeset 1750
- Timestamp:
- 10/16/07 12:53:29
- Files:
-
- trunk/cherrypy/_cperror.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/cherrypy/_cperror.py
r1657 r1750 6 6 from cherrypy.lib import http as _http 7 7 8 8 9 class CherryPyException(Exception): 10 pass 11 12 13 class TimeoutError(CherryPyException): 14 """Exception raised when Response.timed_out is detected.""" 9 15 pass 10 16 … … 186 192 if cherrypy.request.show_tracebacks: 187 193 tb = format_exc() 188 content = get_error_page(self.status, traceback=tb, 189 message=self.message) 194 respheaders['Content-Type'] = "text/html" 195 196 content = self.get_error_page(self.status, traceback=tb, 197 message=self.message) 190 198 response.body = content 191 199 respheaders['Content-Length'] = len(content) 192 respheaders['Content-Type'] = "text/html"193 200 194 201 _be_ie_unfriendly(self.status) 202 203 def get_error_page(self, *args, **kwargs): 204 return get_error_page(*args, **kwargs) 195 205 196 206 def __call__(self): … … 208 218 self.args = (path,) 209 219 HTTPError.__init__(self, 404, "The path %r was not found." % path) 210 211 212 class TimeoutError(CherryPyException):213 """Exception raised when Response.timed_out is detected."""214 pass215 220 216 221

