@@ -260,7 +260,7 @@ def transition_to_abortable_error(self, exc):
260260 with self ._lock :
261261 if self ._current_state == TransactionState .ABORTING_TRANSACTION :
262262 log .debug ("Skipping transition to abortable error state since the transaction is already being "
263- " aborted. Underlying exception: " , exc )
263+ " aborted. Underlying exception: %s " , exc )
264264 return
265265 self ._transition_to (TransactionState .ABORTABLE_ERROR , error = exc )
266266
@@ -687,7 +687,7 @@ def handle_response(self, response):
687687 if error is Errors .NoError :
688688 continue
689689 elif error in (Errors .CoordinatorNotAvailableError , Errors .NotCoordinatorError ):
690- self .transaction_manager ._lookup_coordinator ('transaction' , self .transactiona_id )
690+ self .transaction_manager ._lookup_coordinator ('transaction' , self .transactional_id )
691691 self .reenqueue ()
692692 return
693693 elif error is Errors .ConcurrentTransactionsError :
@@ -726,7 +726,7 @@ def handle_response(self, response):
726726 self .transaction_manager ._pending_partitions_in_transaction -= partitions
727727
728728 if unauthorized_topics :
729- self .abortable_error (Errors .TopicAuthorizationError (unauthorized_topics ))
729+ self .abortable_error (Errors .TopicAuthorizationFailedError (unauthorized_topics ))
730730 elif has_partition_errors :
731731 self .abortable_error (Errors .KafkaError ("Could not add partitions to transaction due to errors: %s" % (results )))
732732 else :
@@ -795,7 +795,7 @@ def handle_response(self, response):
795795 elif error is Errors .TransactionalIdAuthorizationFailedError :
796796 self .fatal_error (error ())
797797 elif error is Errors .GroupAuthorizationFailedError :
798- self .abortable_error (Errors . GroupAuthorizationError (self ._coord_key ))
798+ self .abortable_error (error (self ._coord_key ))
799799 else :
800800 self .fatal_error (Errors .KafkaError (
801801 "Could not find a coordinator with type %s with key %s due to"
@@ -888,7 +888,7 @@ def handle_response(self, response):
888888 elif error is Errors .TransactionalIdAuthorizationFailedError :
889889 self .fatal_error (error ())
890890 elif error is Errors .GroupAuthorizationFailedError :
891- self .abortable_error (Errors . GroupAuthorizationError (self .consumer_group_id ))
891+ self .abortable_error (error (self .consumer_group_id ))
892892 else :
893893 self .fatal_error (Errors .KafkaError ("Unexpected error in AddOffsetsToTxnResponse: %s" % (error ())))
894894
@@ -955,7 +955,7 @@ def handle_response(self, response):
955955 elif error is Errors .UnknownTopicOrPartitionError :
956956 retriable_failure = True
957957 elif error is Errors .GroupAuthorizationFailedError :
958- self .abortable_error (Errors . GroupAuthorizationError (self .consumer_group_id ))
958+ self .abortable_error (error (self .consumer_group_id ))
959959 return
960960 elif error in (Errors .TransactionalIdAuthorizationFailedError ,
961961 Errors .InvalidProducerEpochError ,
0 commit comments