#NEWLINE# def list( options ) : #NEWLINE# #INDENT# '\n    show all currently running jobs\n\n    ' #NEWLINE# configuration = config . get_default ( ) #NEWLINE# app_url = configuration [ 'app_url' ] #NEWLINE# if ( options . deployment != None ) : #NEWLINE# #INDENT# deployment_name = options . deployment #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# deployment_name = configuration [ 'deployment_name' ] #NEWLINE# #UNINDENT# client_id = client_id [ 'client_id' ] #NEWLINE# client_secret = configuration [ 'client_secret' ] #NEWLINE# token_manager = auth . TokenManager ( client_id = client_id , client_secret = client_secret , app_url = app_url ) #NEWLINE# jobs = data_engine . get_jobs ( deployment_name , token_manager = token_manager , app_url = app_url ) #NEWLINE# if ( len ( jobs ) == 0 ) : #NEWLINE# #INDENT# error ( 'No running jobs' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# _print_jobs ( jobs , token_manager , app_url , options )