INNER CODE UNIT · Python
__init__
qodex-ai/apimesh · config.py:6
def __init__(self):
# Get config path from environment variable
config_path = os.environ.get("APIMESH_CONFIG_PATH")
if config_path is None:
raise ValueError(
"APIMESH_CONFIG_PATH environment variable is not set. "
"Please set it to the path of your config.yml file."
)
# Load YAML configurations
self.config = self._load_config(config_path)
# Assign values from the YAML file
self.ignored_dirs = set(self.config.get("ignored_dirs", []))
self.routing_patterns_map = self.config.get("routing_patterns_map", {})
def _load_config(self, config_path):
"""Loads configuration from a YAML file."""