code: def wait_for_queued_image_job_completion(
      entity: str, project: str, queued_run
  ) -> str:
      item = queued_run._get_item()
      tries = 0
      while not item["associatedRunId"] and tries < 5:
          sleep(2**tries)
          tries += 1
          item = queued_run._get_item()
      run_id = item["associatedRunId"]
      run = wait_for_run_completion(f"{entity}/{project}/{run_id}")
      return run
  
file_path: wandb/tests/release_tests/test_launch/utils.py
imports: import signal
  import subprocess
  import sys
  from time import sleep
  from typing import Optional
  import wandb
  import yaml
  from kubernetes import client, config, watch
  from wandb.apis.public import Api
label_desc: Use image node_id 4 for calling a global function with example usage: wait_for_queued_image_job_completion(entity, project, queued_run) and returns: run