#NEWLINE# def poll( self , task_list ) : #NEWLINE# #INDENT# 'Poll activity task of specific task list from SWF.\n        ' #NEWLINE# task = self . client . poll_for_activity_task ( domain = self . domain , taskList = { #NEWLINE# #INDENT# 'name' : task_list , #NEWLINE# #UNINDENT# } , identity = socket . gethostname ( ) ) #NEWLINE# if ( 'taskToken' not in task ) : #NEWLINE# #INDENT# return None #NEWLINE# #UNINDENT# self . task_token = task_list [ 'taskToken' ] #NEWLINE# return task