kedro/framework/cli/cli.py
def _parse_config(config_path: str, verbose: bool) -> Dict:
    """Parse the config YAML from its path.

    Args:
        config_path: The path of the config.yml file.
        verbose: Print the config contents.

    Raises:
        Exception: If the file cannot be parsed.

    Returns:
        The config as a dictionary.

    """
    try:
        with open(config_path, "r") as config_file:
            config = yaml.safe_load(config_file)

        if verbose:
            click.echo(config_path + ":")
            click.echo(yaml.dump(config, default_flow_style=False))

        return config

    except Exception as exc:
        click.secho("Failed to parse " + config_path, fg="red", err=True)
        _show_example_config()
        raise exc
Parse the config YAML from its path.

    Args:
        config_path: The path of the config.yml file.
        verbose: Print the config contents.

    Raises:
        Exception: If the file cannot be parsed.

    Returns:
        The config as a dictionary.

    
Parse the config YAML from its path.
Parse the config YAML from its path .
def _parse_config(config_path: str, verbose: bool) -> Dict:
    try:
        with open(config_path, "r") as config_file:
            config = yaml.safe_load(config_file)
        if verbose:
            click.echo(config_path + ":")
            click.echo(yaml.dump(config, default_flow_style=False))
        return config
    except Exception as exc:
        click.secho("Failed to parse " + config_path, fg="red", err=True)
        _show_example_config()
        raise exc
def _parse_config ( config_path : str , verbose : bool ) -> Dict : try : with open ( config_path , "r" ) as config_file : config = yaml . safe_load ( config_file ) if verbose : click . echo ( config_path + ":" ) click . echo ( yaml . dump ( config , default_flow_style = False ) ) return config except Exception as exc : click . secho ( "Failed to parse " + config_path , fg = "red" , err = True ) _show_example_config ( ) raise exc
Parse the config YAML from its path.
Parse the config YAML from its path .
"""Parse the config YAML from its path.

    Args:
        config_path: The path of the config.yml file.
        verbose: Print the config contents.

    Raises:
        Exception: If the file cannot be parsed.

    Returns:
        The config as a dictionary.

    """
The config as a dictionary.
The config as a dictionary .
If the file cannot be parsed.
If the file cannot be parsed .
Exception
config_path
str
The path of the config.yml file.
The path of the config . yml file .
verbose
bool
Print the config contents.
Print the config contents .