From a2c4dd85688dbef37d77aae14b3c50ae25359eab Mon Sep 17 00:00:00 2001 From: Alexander Schlemmer <alexander@mail-schlemmer.de> Date: Fri, 5 May 2023 12:55:05 +0200 Subject: [PATCH] DOC: comment for improving recursion detection --- src/caosdb/apiutils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/caosdb/apiutils.py b/src/caosdb/apiutils.py index a5a936c5..28e9a410 100644 --- a/src/caosdb/apiutils.py +++ b/src/caosdb/apiutils.py @@ -300,6 +300,7 @@ def compare_entities(old_entity: Entity, new_entity: Entity, compare_referenced_ # scalar reference if isinstance(prop.value, Entity) and isinstance(matching[0].value, Entity): # explicitely not recursive to prevent infinite recursion + # TODO: why not use a recursion detection with a cache? same_value = empty_diff( prop.value, matching[0].value, compare_referenced_records=False) # list of references -- GitLab