code: def _cli_check_family(family, data_dir):
      '''Checks that a basis set family exists and if not, raises a helpful exception'''
  
      if family is None:
          return None
  
      family = family.lower()
      if not family in api.get_families(data_dir):
          errstr = "Basis set family '" + family + "' does not exist.\n"
          errstr += "For a complete list of families, use the 'bse list-families' command"
          raise RuntimeError(errstr)
  
      return familf _cli_check_family(family, data_dir):
      '''Checks that a basis set family exists and if not, raises a helpful exception'''
  
      if family is None:
          return None
  
      family = family.lower()
      if not family in api.get_families(data_dir):
          errstr = "Basis set family '" + family + "' does not exist.\n"
          errstr += "For a complete list of families, use the 'bse list-families' command"
          raise RuntimeError(errstr)
  
      return family
docs: Checks that a basis set family exists and if not, raises a helpful exception