diff --git a/src/pynxtools/dataconverter/readers/multi/reader.py b/src/pynxtools/dataconverter/readers/multi/reader.py index da19b0139..4a11f5db7 100644 --- a/src/pynxtools/dataconverter/readers/multi/reader.py +++ b/src/pynxtools/dataconverter/readers/multi/reader.py @@ -50,7 +50,12 @@ def get_vals_on_same_level(key): dim_dict = {} for dim in dims: new_key = key.replace("*", dim) - new_val = value.replace("*", dim) + if isinstance(value, str): + new_val = value.replace("*", dim) + elif isinstance(value, list): + new_val = [val.replace("*", dim) for val in value] + else: + new_val = value if new_key not in config_file_dict and new_val not in get_vals_on_same_level( new_key @@ -283,7 +288,8 @@ def dict_sort_key(keyval: Tuple[str, Any]) -> bool: if "*" in key: dims = callbacks.dims(key, value) dim_data = fill_wildcard_data_indices(config_dict, key, value, dims) - for k, v in dim_data.items(): + + for k, v in dim_data.copy().items(): resolve_special_keys( dim_data, k,