From 488415436c644197c6b37fc40f93e5096d453752 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mose=20M=C3=BCller?= Date: Sat, 21 Sep 2024 08:32:54 +0200 Subject: [PATCH] fixes recursion when defining task without autostart --- src/pydase/task/autostart.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pydase/task/autostart.py b/src/pydase/task/autostart.py index 234b2a9..5d45be1 100644 --- a/src/pydase/task/autostart.py +++ b/src/pydase/task/autostart.py @@ -17,7 +17,9 @@ def autostart_service_tasks( """ for attr in dir(service): - if is_property_attribute(service, attr): # prevent eval of property attrs + if is_property_attribute(service, attr) or attr in { + "__dict__", + }: # prevent eval of property attrs and recursion continue val = getattr(service, attr)