@@ -100,7 +100,7 @@ def on_backfill_request(self, origin, room_id, versions, limit):
100100
101101 res = self ._transaction_from_pdus (pdus ).get_dict ()
102102
103- return ( 200 , res )
103+ return 200 , res
104104
105105 @defer .inlineCallbacks
106106 @log_function
@@ -163,7 +163,7 @@ def _handle_incoming_transaction(self, origin, transaction, request_time):
163163 yield self .transaction_actions .set_response (
164164 origin , transaction , 400 , response
165165 )
166- return ( 400 , response )
166+ return 400 , response
167167
168168 received_pdus_counter .inc (len (transaction .pdus ))
169169
@@ -265,7 +265,7 @@ def process_pdus_for_room(room_id):
265265 logger .debug ("Returning: %s" , str (response ))
266266
267267 yield self .transaction_actions .set_response (origin , transaction , 200 , response )
268- return ( 200 , response )
268+ return 200 , response
269269
270270 @defer .inlineCallbacks
271271 def received_edu (self , origin , edu_type , content ):
@@ -298,7 +298,7 @@ def on_context_state_request(self, origin, room_id, event_id):
298298 event_id ,
299299 )
300300
301- return ( 200 , resp )
301+ return 200 , resp
302302
303303 @defer .inlineCallbacks
304304 def on_state_ids_request (self , origin , room_id , event_id ):
@@ -315,7 +315,7 @@ def on_state_ids_request(self, origin, room_id, event_id):
315315 state_ids = yield self .handler .get_state_ids_for_pdu (room_id , event_id )
316316 auth_chain_ids = yield self .store .get_auth_chain_ids (state_ids )
317317
318- return ( 200 , {"pdu_ids" : state_ids , "auth_chain_ids" : auth_chain_ids })
318+ return 200 , {"pdu_ids" : state_ids , "auth_chain_ids" : auth_chain_ids }
319319
320320 @defer .inlineCallbacks
321321 def _on_context_state_request_compute (self , room_id , event_id ):
@@ -345,15 +345,15 @@ def on_pdu_request(self, origin, event_id):
345345 pdu = yield self .handler .get_persisted_pdu (origin , event_id )
346346
347347 if pdu :
348- return ( 200 , self ._transaction_from_pdus ([pdu ]).get_dict () )
348+ return 200 , self ._transaction_from_pdus ([pdu ]).get_dict ()
349349 else :
350- return ( 404 , "" )
350+ return 404 , ""
351351
352352 @defer .inlineCallbacks
353353 def on_query_request (self , query_type , args ):
354354 received_queries_counter .labels (query_type ).inc ()
355355 resp = yield self .registry .on_query (query_type , args )
356- return ( 200 , resp )
356+ return 200 , resp
357357
358358 @defer .inlineCallbacks
359359 def on_make_join_request (self , origin , room_id , user_id , supported_versions ):
@@ -435,7 +435,7 @@ def on_send_leave_request(self, origin, content, room_id):
435435
436436 logger .debug ("on_send_leave_request: pdu sigs: %s" , pdu .signatures )
437437 yield self .handler .on_send_leave_request (origin , pdu )
438- return ( 200 , {})
438+ return 200 , {}
439439
440440 @defer .inlineCallbacks
441441 def on_event_auth (self , origin , room_id , event_id ):
@@ -446,7 +446,7 @@ def on_event_auth(self, origin, room_id, event_id):
446446 time_now = self ._clock .time_msec ()
447447 auth_pdus = yield self .handler .on_event_auth (event_id )
448448 res = {"auth_chain" : [a .get_pdu_json (time_now ) for a in auth_pdus ]}
449- return ( 200 , res )
449+ return 200 , res
450450
451451 @defer .inlineCallbacks
452452 def on_query_auth_request (self , origin , content , room_id , event_id ):
@@ -499,7 +499,7 @@ def on_query_auth_request(self, origin, content, room_id, event_id):
499499 "missing" : ret .get ("missing" , []),
500500 }
501501
502- return ( 200 , send_content )
502+ return 200 , send_content
503503
504504 @log_function
505505 def on_query_client_keys (self , origin , content ):
0 commit comments