loader
attributelogger= logging.getLogger(__name__)funcload_specs_from_directoryload_specs_from_directory(directory, /, registry, *, recursive=True, strict=False, patterns=None) -> list[Component[Any]]Traverse directory recursively and load YAML files, creating corresponding components based on kind.
Args: directory: Directory path to traverse registry: Registry instance for node creation recursive: Whether to traverse subdirectories strict: Whether to enforce strict validation patterns: File patterns to match (default: [".yaml", ".yml"])
Returns: List of loaded components
Raises: YamlLoaderError: When there's an error loading YAML files FileNotFoundError: When directory doesn't exist
paramdirectorystr | PathparamregistryRegistryparamrecursivebool= Trueparamstrictbool= Falseparampatternslist[str] | None= NoneReturns
list[Component[Any]]func_find_yaml_files_find_yaml_files(directory, /, recursive, patterns) -> list[Path]Find YAML files in directory using multiple patterns.
paramdirectoryPathparamrecursiveboolparampatternslist[str]Returns
list[Path]func_load_nodes_from_yaml_load_nodes_from_yaml(yaml_file, /, registry, strict) -> list[Component[Any]]Load nodes from a YAML file that may contain single or multiple documents.
paramyaml_filePathparamregistryRegistryparamstrictboolReturns
list[Component[Any]]func_create_node_from_yaml_data_create_node_from_yaml_data(yaml_data, /, yaml_file, registry, strict) -> Component[Any] | NoneCreate a node from YAML data.
paramyaml_dataAnyparamyaml_filePathparamregistryRegistryparamstrictboolReturns
Component[Any] | NoneLast updated on