config¶
Config module.
-
spicerack.config.
load_ini_config
(config_file)[source]¶ Parse an INI config file and return it.
Parameters: config_file (str) -- the path of the configuration file. Returns: the parsed config. Return type: configparser.ConfigParser
-
spicerack.config.
load_yaml_config
(config_file, raises=True)[source]¶ Parse a YAML config file and return it, optionally not failing on error.
Parameters: Returns: the parsed config or an empty dictionary as a fallback when
raises
isFalse
.Return type: Raises: SpicerackError
-- if unable to load the configuration andraises
isTrue
.