From 17216c5b8f0a1950a554a5d4252a3d4fe1450640 Mon Sep 17 00:00:00 2001 From: Jonas Dech Date: Fri, 28 Jun 2024 10:10:31 +0200 Subject: [PATCH] [WorldObject] Code and doc cleanup --- src/pycram/world_concepts/world_object.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/pycram/world_concepts/world_object.py b/src/pycram/world_concepts/world_object.py index 4bc2485dc..2f47f39b6 100644 --- a/src/pycram/world_concepts/world_object.py +++ b/src/pycram/world_concepts/world_object.py @@ -575,10 +575,8 @@ def set_attachments(self, attachments: Dict[Object, Attachment]) -> None: """ for obj, attachment in attachments.items(): if self.world.is_prospection_world and not obj.world.is_prospection_world: - # The object mapping is directly used since this function can be called from the world sync thread which - # would cause a deadlock when calling get_prospection_object_for_object. - # Furthermore, all attached objects are spawned beforehand so no keyError should occur - # obj = self.world.world_sync.object_mapping[obj] + # In case this object is in the prospection world and the other object is not, the attachment will no + # be set. continue if obj in self.attachments: if self.attachments[obj] != attachment: