aztk/utils/helpers.py
def wait_for_tasks_to_complete(job_id, batch_client):
    """
    Waits for all the tasks in a particular job to complete.
    :param batch_client: The batch client to use.
    :type batch_client: `batchserviceclient.BatchServiceClient`
    :param str job_id: The id of the job to monitor.
    """
    while True:
        tasks = batch_client.task.list(job_id)

        incomplete_tasks = [task for task in tasks if task.state != batch_models.TaskState.completed]
        if not incomplete_tasks:
            return
        time.sleep(5)

    Waits for all the tasks in a particular job to complete.
    :param batch_client: The batch client to use.
    :type batch_client: `batchserviceclient.BatchServiceClient`
    :param str job_id: The id of the job to monitor.
    
Waits for all the tasks in a particular job to complete.
Waits for all the tasks in a particular job to complete .
def wait_for_tasks_to_complete(job_id, batch_client):
    while True:
        tasks = batch_client.task.list(job_id)
        incomplete_tasks = [task for task in tasks if task.state != batch_models.TaskState.completed]
        if not incomplete_tasks:
            return
        time.sleep(5)
def wait_for_tasks_to_complete ( job_id , batch_client ) : while True : tasks = batch_client . task . list ( job_id ) incomplete_tasks = [ task for task in tasks if task . state != batch_models . TaskState . completed ] if not incomplete_tasks : return time . sleep ( 5 )
Waits for all the tasks in a particular job to complete.
Waits for all the tasks in a particular job to complete .
"""
    Waits for all the tasks in a particular job to complete.
    :param batch_client: The batch client to use.
    :type batch_client: `batchserviceclient.BatchServiceClient`
    :param str job_id: The id of the job to monitor.
    """
job_id
The id of the job to monitor.
The id of the job to monitor .
batch_client
The batch client to use.
The batch client to use .