mirror of
				https://git.anonymousland.org/anonymousland/synapse.git
				synced 2025-10-31 16:18:55 -04:00 
			
		
		
		
	Cleanup top level request exception logging
Firstly, we always logged that the request was being handled via `JsonResource._async_render`, so we change that to use the servlet name we add to the request. Secondly, we pass the exception information to the logger rather than formatting it manually. This makes it consistent with other exception logging, allwoing logging hooks and formatters to access the exception information.
This commit is contained in:
		
							parent
							
								
									d1b060b492
								
							
						
					
					
						commit
						fe725f7e45
					
				
					 1 changed files with 3 additions and 3 deletions
				
			
		|  | @ -106,10 +106,10 @@ def wrap_json_request_handler(h): | |||
|             # trace. | ||||
|             f = failure.Failure() | ||||
|             logger.error( | ||||
|                 "Failed handle request via %r: %r: %s", | ||||
|                 h, | ||||
|                 "Failed handle request via %r: %r", | ||||
|                 request.request_metrics.name, | ||||
|                 request, | ||||
|                 f.getTraceback().rstrip(), | ||||
|                 exc_info=(f.type, f.value, f.getTracebackObject()), | ||||
|             ) | ||||
|             # Only respond with an error response if we haven't already started | ||||
|             # writing, otherwise lets just kill the connection | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Erik Johnston
						Erik Johnston