mirror of
https://github.com/tiqi-group/pydase.git
synced 2025-04-20 08:20:02 +02:00
updates ProxyClassFactory (go through handled types before components)
This commit is contained in:
parent
31f280c9cb
commit
612e62d06b
@ -45,6 +45,11 @@ class ProxyClassFactory:
|
||||
"Exception": loads,
|
||||
}
|
||||
|
||||
# First go through handled types (as ColouredEnum is also within the components)
|
||||
handler = type_handler.get(serialized_object["type"])
|
||||
if handler:
|
||||
return handler(serialized_object)
|
||||
|
||||
# Custom types like Components or DataService classes
|
||||
component_class = Deserializer.get_component_class(serialized_object["type"])
|
||||
if component_class:
|
||||
@ -53,10 +58,6 @@ class ProxyClassFactory:
|
||||
)
|
||||
proxy_class._sio = self.sio_client
|
||||
return proxy_class
|
||||
|
||||
handler = type_handler.get(serialized_object["type"])
|
||||
if handler:
|
||||
return handler(serialized_object)
|
||||
return None
|
||||
|
||||
def _deserialize_method(self, serialized_object: SerializedObject) -> Any:
|
||||
|
Loading…
x
Reference in New Issue
Block a user