code: def _wait_for_running(state):
      while True:
          _release_futures(state)
          log.debug("wait_for_running futures: %i", len(state.futures))
          if not state.futures:
              break
          time.sleep(WAIT_FOR_RUNNING_DELAY)
  
imports: import argparse
  import logging
  import time
  from guild import _api
  from guild import util
  from .None import gen_queue
label_desc: Use image node_id 31 for calling a global function with example usage: _wait_for_running(state) without return types