Skip to content

Commit

Permalink
pass parent key to parse_yml
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaspie committed Jul 25, 2024
1 parent f849c78 commit a0242ba
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/pynxtools/dataconverter/readers/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class FlattenSettings:
dic: Mapping
convert_dict: dict
replace_nested: dict
parent_key: str = "/ENTRY"
parent_key: str = "/ENTRY[entry]"
sep: str = "/"
is_in_section: bool = False
ignore_keys: Optional[list] = None
Expand Down Expand Up @@ -174,6 +174,7 @@ def parse_yml(
file_path: str,
convert_dict: Optional[dict] = None,
replace_nested: Optional[dict] = None,
parent_key: str = "/ENTRY[entry]",
) -> Dict[str, Any]:
"""Parses a metadata yaml file into a dictionary.
Expand All @@ -197,6 +198,7 @@ def parse_yml(
dic=yaml.safe_load(file),
convert_dict=convert_dict,
replace_nested=replace_nested,
parent_key=parent_key,
)
)

Expand Down

0 comments on commit a0242ba

Please sign in to comment.