docs: def str_to_bool(val):
      """ Return a boolean if the string value represents one
  
      :param val: str
      :return: bool
      :raise: ValueError
      """
  
      if isinstance(val, bool):
          return val
      elif val.lower() == 'true':
          return True
      elif val.lower() == 'false':
          return False
      else:
          raise ValueError