fixes error in dict_merge when merging list value (#35461)
This commit is contained in:
parent
359ff19484
commit
2f7d207d7a
1 changed files with 5 additions and 1 deletions
|
@ -284,7 +284,11 @@ def dict_merge(base, other):
|
|||
if key in other:
|
||||
item = other.get(key)
|
||||
if item is not None:
|
||||
combined[key] = list(set(chain(value, item)))
|
||||
try:
|
||||
combined[key] = list(set(chain(value, item)))
|
||||
except TypeError:
|
||||
value.extend([i for i in item if i not in value])
|
||||
combined[key] = value
|
||||
else:
|
||||
combined[key] = item
|
||||
else:
|
||||
|
|
Loading…
Reference in a new issue