docs: def check_table(
      problems: List,
      table: str,
      df: DataFrame,
      condition,
      message: str,
      type_: str = "error",
  ) -> List:
      """
      Check the given GTFS table for the given problem condition.
  
      Parameters
      ----------
      problems : list
          A four-tuple containing
  
          1. A problem type (string) equal to ``'error'`` or ``'warning'``;
             ``'error'`` means the GTFS is violated;
             ``'warning'`` means there is a problem but it is not a
             GTFS violation
          2. A message (string) that describes the problem
          3. A GTFS table name, e.g. ``'routes'``, in which the problem
             occurs
          4. A list of rows (integers) of the table's DataFrame where the
             problem occurs
  
      table : string
          Name of a GTFS table
      df : DataFrame
          The GTFS table corresponding to ``table``
      condition : boolean expression
          One involving ``df``, e.g.`df['route_id'].map(is_valid_str)``
      message : string
          Problem message, e.g. ``'Invalid route_id'``
      type_ : string
          ``'error'`` or ``'warning'`` indicating the type of problem
          encountered
  
      Returns
      -------
      list
          The ``problems`` list extended as follows.
          Record the indices of ``df`` that statisfy the condition.
          If the list of indices is nonempty, append to the
          problems the item ``[type_, message, table, indices]``;
          otherwise do not append anything.
  
      """
      indices = df.loc[condition].index.tolist()
      if indices:
          problems.append([type_, message, table, indices])
  
      return problems