From 54215ddfb1e0d720f151524a716b493cac89b131 Mon Sep 17 00:00:00 2001 From: Kyle Johnsen Date: Fri, 14 Jul 2023 17:19:40 -0400 Subject: [PATCH] enable merging of groups --- neo/core/container.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/neo/core/container.py b/neo/core/container.py index 89554a139..716ce32b6 100644 --- a/neo/core/container.py +++ b/neo/core/container.py @@ -514,7 +514,8 @@ def merge(self, other): lookup[obj.name] = obj ids.append(id(obj)) getattr(self, container).append(obj) - obj.set_parent(self) + if self.__class__.__name__ in obj._parent_objects: + obj.set_parent(self) # use the BaseNeo merge as well super().merge(other)