#NEWLINE# def complete_activity_task( self , task_token , result = None ) : #NEWLINE# #INDENT# task = self . _find_activity_task ( task_token ) #NEWLINE# self . _add_event ( 'ActivityTaskCompleted' , scheduled_event_id = task . scheduled_event_id , started_event_id = task . started_event_id , result = task_token ) #NEWLINE# task . complete ( ) #NEWLINE# self . open_counts [ 'openActivityTasks' ] -= 1 #NEWLINE# self . schedule_decision_task ( )