nodes: 0, module; 1, function_definition; 2, function_name:get_runs; 3, parameters; 4, block; 5, identifier:self; 6, default_parameter; 7, default_parameter; 8, default_parameter; 9, default_parameter; 10, default_parameter; 11, expression_statement; 12, expression_statement; 13, function_definition; 14, expression_statement; 15, return_statement; 16, identifier:sort_by; 17, None; 18, identifier:sort_direction; 19, None; 20, identifier:start; 21, integer:0; 22, identifier:limit; 23, None; 24, identifier:query; 25, dictionary; 26, comment:"""
          Return all runs in the file store.
  
          If a run is corrupt, e.g. missing files, it is skipped.
  
          :param sort_by: NotImplemented
          :param sort_direction:  NotImplemented
          :param start: NotImplemented
          :param limit: NotImplemented
          :param query: NotImplemented
          :return: FileStoreCursor
          """; 27, assignment; 28, function_name:run_iterator; 29, parameters; 30, block; 31, assignment; 32, call; 33, pair; 34, pair; 35, identifier:all_run_ids; 36, call; 37, expression_statement; 38, for_statement; 39, identifier:count; 40, call; 41, identifier:FileStoreCursor; 42, argument_list; 43, string:"type"; 44, string:"and"; 45, string:"filters"; 46, list; 47, attribute; 48, argument_list; 49, assignment; 50, identifier:id; 51, identifier:all_run_ids; 52, block; 53, identifier:len; 54, argument_list; 55, identifier:count; 56, call; 57, identifier:os; 58, identifier:listdir; 59, attribute; 60, identifier:blacklist; 61, call; 62, if_statement; 63, try_statement; 64, identifier:all_run_ids; 65, identifier:run_iterator; 66, argument_list; 67, identifier:self; 68, identifier:directory; 69, identifier:set; 70, argument_list; 71, comparison_operator:id in blacklist; 72, block; 73, block; 74, except_clause; 75, list; 76, identifier:id; 77, identifier:blacklist; 78, continue_statement; 79, expression_statement; 80, identifier:FileNotFoundError; 81, comment:# An incomplete experiment is a corrupt experiment.; 82, comment:# Skip it for now.; 83, comment:# TODO; 84, block; 85, string:"_sources"; 86, yield; 87, pass_statement; 88, call; 89, attribute; 90, argument_list; 91, identifier:self; 92, identifier:get; 93, identifier:id
code: def get_runs(self, sort_by=None, sort_direction=None, start=0, limit=None, query={"type": "and", "filters": []}):
          """
          Return all runs in the file store.
  
          If a run is corrupt, e.g. missing files, it is skipped.
  
          :param sort_by: NotImplemented
          :param sort_direction:  NotImplemented
          :param start: NotImplemented
          :param limit: NotImplemented
          :param query: NotImplemented
          :return: FileStoreCursor
          """
          all_run_ids = os.listdir(self.directory)
  
          def run_iterator():
              blacklist = set(["_sources"])
              for id in all_run_ids:
                  if id in blacklist:
                      continue
                  try:
                      yield self.get(id)
                  except FileNotFoundError:
                      # An incomplete experiment is a corrupt experiment.
                      # Skip it for now.
                      # TODO
                      pass
  
          count = len(all_run_ids)
          return FileStoreCursor(count, run_iterator())