def get_config_string_option(parser: ConfigParser,
                             section: str,
                             option: str,
                             default: str = None) -> str:
    """
    Retrieves a string value from a parser.

    Args:
        parser: instance of :class:`ConfigParser`
        section: section name within config file
        option: option (variable) name within that section
        default: value to return if option is absent

    Returns:
        string value

    Raises:
        ValueError: if the section is absent

    """
    if not parser.has_section(section):
        raise ValueError("config missing section: " + section)
    return parser.get(section, option, fallback=default)
def get_config_string_option ( parser : ConfigParser , section : str , option : str , default : str = None ) -> str : if not parser . has_section ( section ) : raise ValueError ( "config missing section: " + section ) return parser . get ( section , option , fallback = default )
Retrieves a string value from a parser.

    Args:
        parser: instance of :class:`ConfigParser`
        section: section name within config file
        option: option (variable) name within that section
        default: value to return if option is absent

    Returns:
        string value

    Raises:
        ValueError: if the section is absent