From 964a62d4b4030f06a4b2f9284f5f5a6f7f68fca8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mose=20M=C3=BCller?= Date: Mon, 23 Sep 2024 13:33:13 +0200 Subject: [PATCH] removes inheritance warning for descriptors --- src/pydase/data_service/data_service.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pydase/data_service/data_service.py b/src/pydase/data_service/data_service.py index 538f5ff..e625ad9 100644 --- a/src/pydase/data_service/data_service.py +++ b/src/pydase/data_service/data_service.py @@ -10,6 +10,7 @@ from pydase.observer_pattern.observable.observable import ( ) from pydase.utils.helpers import ( get_class_and_instance_attributes, + is_descriptor, is_property_attribute, ) from pydase.utils.serialization.serializer import ( @@ -68,7 +69,7 @@ class DataService(AbstractDataService): if not issubclass( value_class, (int | float | bool | str | list | dict | Enum | u.Quantity | Observable), - ): + ) and not is_descriptor(__value): logger.warning( "Class '%s' does not inherit from DataService. This may lead to" " unexpected behaviour!",