in composer_local_dev/environment.py [0:0]
def load_configuration_from_file(self) -> Dict:
"""
Load environment configuration from json file.
Returns:
Dict:
Environment configuration dictionary.
"""
config_path = self.env_dir_path / "config.json"
LOG.info("Loading configuration file from %s", config_path)
if not config_path.is_file():
raise errors.ComposerCliError(
f"Configuration file '{config_path}' not found."
)
with open(config_path) as fp:
try:
config = json.load(fp)
except json.JSONDecodeError as err:
raise errors.FailedToParseConfigError(config_path, err)
return config