Python API

tpl.merge_data(old: dict, new, array_key='_array_data', scalar_key='_scalar_data')[source]

Merge the data from the different sources.

If the new value is a list it’s elements will get appended to the list in _array_data.

If the new value is a scalar (anything not a list or dict) it will replace the value in _scalar_data.

if the new value is a dict it’s elements will get merged with the elements already present. This also means that sub dicts in both values will get merged.