code: def _check_task_done(self):
          '''Check status queue'''
          cnt = 0
          try:
              while True:
                  task = self.status_queue.get_nowait()
                  # check _on_get_info result here
                  if task.get('taskid') == '_on_get_info' and 'project' in task and 'track' in task:
                      if task['project'] not in self.projects:
                          continue
                      project = self.projects[task['project']]
                      project.on_get_info(task['track'].get('save') or {})
                      logger.info(
                          '%s on_get_info %r', task['project'], task['track'].get('save', {})
                      )
                      continue
                  elif not self.task_verify(task):
                      continue
                  self.on_task_status(task)
                  cnt += 1
          except Queue.Empty:
              pass
          return cnf _check_task_done(self):
          '''Check status queue'''
          cnt = 0
          try:
              while True:
                  task = self.status_queue.get_nowait()
                  # check _on_get_info result here
                  if task.get('taskid') == '_on_get_info' and 'project' in task and 'track' in task:
                      if task['project'] not in self.projects:
                          continue
                      project = self.projects[task['project']]
                      project.on_get_info(task['track'].get('save') or {})
                      logger.info(
                          '%s on_get_info %r', task['project'], task['track'].get('save', {})
                      )
                      continue
                  elif not self.task_verify(task):
                      continue
                  self.on_task_status(task)
                  cnt += 1
          except Queue.Empty:
              pass
          return cnt
docs: Check status queue