From 056a60269e65294a54bb1987f3376de78fc3f7fa Mon Sep 17 00:00:00 2001 From: David Bremer <120127082+david-bremer@users.noreply.github.com> Date: Fri, 11 Oct 2024 09:12:29 -0400 Subject: [PATCH] Fix part updates on palette change (#451) --- src/ansys/pyensight/core/utils/dsg_server.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ansys/pyensight/core/utils/dsg_server.py b/src/ansys/pyensight/core/utils/dsg_server.py index b281ea0d815..2a6697fc69f 100644 --- a/src/ansys/pyensight/core/utils/dsg_server.py +++ b/src/ansys/pyensight/core/utils/dsg_server.py @@ -101,6 +101,12 @@ def update_geom(self, cmd: dynamic_scene_graph_pb2.UpdateGeom) -> None: self.tcoords[ cmd.chunk_offset : cmd.chunk_offset + len(cmd.flt_array) ] = cmd.flt_array + + # Add the variable hash to the Part's hash, to pick up palette changes + var_cmd = self.session.variables.get(cmd.variable_id, None) + if var_cmd is not None: + self.hash.update(var_cmd.hash.encode("utf-8")) + if self.cmd.node_size_variableid == cmd.variable_id: # type: ignore # Receive the node size var values if self.node_sizes.size != cmd.total_array_size: