Skip to content

Commit

Permalink
Update merging_manager.py
Browse files Browse the repository at this point in the history
  • Loading branch information
azerty9971 committed Jan 26, 2025
1 parent 66379b0 commit 05abc39
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,10 @@ def smart_merge(left: any, right: any, msg_queue: list[str] | None = None, path:
if left is not None:
return left
return right
if type(left) != type(right):
if (
type(left) is not type(right)
and not (isinstance(left, str) and isinstance(right, str)) #Used to prevent warning on classes that represent a string (DPType and TuyaDPType)
):
if msg_queue is not None:
msg_queue.append(f"Merging tried to merge objects of different types: {type(left)} and {type(right)}, returning left ({path})")
return left
Expand Down

0 comments on commit 05abc39

Please sign in to comment.