text: Title: [OTHER] Taipy unable to assign a state variable, apparent leak between clients?
  Body: ### What went wrong? 🤔
  
  I've been stuck on a really critical bug for the past week. It's preventing pages from loading, and the only current workaround is restarting the server. It occurs (seemingly) random, even with automated tests.
  
  The issue arises a nested dict-like data structure object is saved to a state variable. This object is used to save datasets, figures, values, etc. The size of this data structure is dynamic and is different for each client session, defined by a query parameter in the URL called `client_handle` (important). The data structure is constructed during `on_init()` of the page without any issue, and then assigned to a state variable in a simple line: `state.risk_tree = tree` which causes the (occasional) error.
  
  The first client to connect to the server (since server startup) always initializes without a problem. Subsequent clients can have the issue, *if they use a different `client_handle`*. For example, assuming each client connects from an isolated browser and creates its own Taipy session:
  
  1. `client_handle = vm_groningen_dev` (initialization OK)
  2. `client_handle = vm_gelderland_dev` (initialization OK)
  3. `client_handle = vm_limburg_dev` (ERROR)
  
  
  The error raised by during the initialization of connection #3 (`vm_limburg_dev`) is: 
  ```
  File "taipy/gui/utils/_attributes.py", line 26, in _getscopeattr_drill 
    return attrgetter(name)(gui._get_data_scope())
  AttributeError("'types.SimpleNamespace' object has no attribute 'tp_TpExPr_gui_get_adapted_lov_risk_tree_vm_gelderland_dev_root_0_thema_2_rp_0_ind_0_var_CHART_AGG_LOV_str_TPMDL_9_0'")
  ```
  This long attribute id refers to the key which is used to retrieve an element from the data structure (in this case an LOV).
  
  **Note:** in the middle of the attribute id is a part `vm_gelderland_dev` (the  `client_handle`). The currently connected client is `vm_limburg_dev`. **This indicates Taipy is trying to bind a callback from another client session, which it obviously cannot find in this session.**
  
  
  
  ### Expected Behavior
  
  The state variable `state.risk_tree` should be set. 9/10 times this works without a problem.
  
  ### Steps to Reproduce Issue
  
  The biggest difficulty is that this bug is not consistent. 9/10 times it works fine, even when I reproduce client page-visit combinations that previously caused an error. So the only way to debug this is by inspecting the logs. I realize this is very little to go off, but since I can't even reliably reproduce the error, creating a minimum example is pretty much impossible. 
  
  See [isolated_error.log](https://github.com/user-attachments/files/18706548/bug951_isolated_error.log), which also contains the variables. The actions to produce this:
  - The first 5 entries show how a client with `client_handle = vm_gelderland_dev` initializes without an issue. 
  - Browser is then closed.
  - New browser is opened, client with `client_handle = vm_limburg_dev` fails to initialize.
     - *Note that the error contains the `client_handle` of the previous client*
  
  
  
  The issue occurs in the page `on_init()`. Constructing the object works without an issue. Saving the object to a state variable causes the issue.
  
  ```python
  <imports>
  # Declare page state variable
  risk_tree = None
  
  def on_init(state):
      # Create the basic tree structure based on client settings. Data is added later in Long-Running Callback
      state_var_name = "risk_tree"
      tree = TreeRoot(
          client_subniveau=state.client_settings["subniveau"],
          client_alt_subniveaus=state.client_settings["subniveau_alt"],
          state_var_name=state_var_name,
          client_handle=state.client_handle,
          children=[
              ThemaNode(
                  id=idx,
                  thema_naam=thema,
                  risico_profielen=risicos,
                  state_var_name=state_var_name,
              )
              for idx, (thema, risicos) in enumerate(state.client_settings["risico_themas"].items())
          ],
          client_settings=state.client_settings,
          client_data_ops_fn=apply_client_allpages_data_operations,
      )
  
      state.risk_tree = tree # ERROR OCCURS HERE
      
      tpgui.invoke_long_callback(
          state=state,
          user_function=LRCB_load_risicotree_data,
          user_function_args=[
              state.get_gui(),
              tpgui.get_state_id(state),
              tree,
              state.client_handle,
              state.pg_uri,
          ],
          user_status_function=status_LRCB_tree_loading,  # invoked at the end of and possibly during the runtime of user_function
          period=10000,  # Interval in milliseconds to check the status of the long callback
      )
  ```
  
  After the Long-Running Callback is complete, a Taipy Partial generates the content of the page. As seen below, the GUI elements reference attributes inside the data structure.
  
  ```python
  def create_taipy_partial_content(tree_node, page_context=None):
      """Create the content for the current node in the Taipy Page format
      """
      class_name = f"{tree_node.css_class_name} content-block"
  
      # All other nodes (RisicoNode, IndicatorNode, VariabeleNode)
      with tgb.part(class_name=class_name) as content:
          if is_thema_node:
              # Just title
              tgb.text(
                  f"## {tree_node.get_label_text().upper()}",
                  mode="markdown",
                  class_name="card-title",
              )
  
          else:
              # Title and link to docs
              with tgb.layout(columns="2 1"):
                  tgb.text(
                      f"**{tree_node.get_label_text().title()}**",
                      mode="markdown",
                      class_name="card-title",
                  )
                  tgb.button(
                      "{docs_icon}",                   # docs_icon is defined in main.py
                      on_action="{navigate_to_docs}",  # navigate_to_docs is defined in main.py
                      class_name="docs-button",
                      hover_text="Open documentatie",
                  )
  
          # Description
          tgb.text(f"{tree_node.help}", mode="markdown")
  
          # Figure
          if tree_node.figure is not None and tree_node.selected:
              tgb.toggle(
                  value="{"
                  + f"{tree_node.state_var_name}['{tree_node.id}']" #client_handle is part of the tree_node.id
                  + ".chart_agg_toggle}",
                  lov="{"
                  + f"{tree_node.state_var_name}['{tree_node.id}']"
                  + ".CHART_AGG_LOV}",
                  on_change=callback_chart_agg_toggle,
              )
              tgb.chart(
                  figure="{"
                  + f"{tree_node.state_var_name}['{tree_node.id}']"
                  + ".figure}"
              )
  
          # Build children in nested content blocks
          for child in tree_node.children:
              if child.count_selected() == 0:
                  continue
              create_taipy_partial_content(child)
  
      return content
  ```
  
  ### Runtime Environment
  
  Docker Container: python:3.12-slim-bookworm
  
  ### Browsers
  
  Chrome, Firefox, Safari
  
  ### Version of Taipy
  
  4.0.2
  
  ### Additional Context
  
  ```bash
  
  ```
  
  ### Acceptance Criteria
  
  - [ ] A unit test reproducing the bug is added.
  - [ ] Any new code is covered by a unit tested.
  - [ ] Check code coverage is at least 90%.
  - [ ] The bug reporter validated the fix.
  - [ ] Related issue(s) in taipy-doc are created for documentation and Release Notes are updated.
  
  
  ### Code of Conduct
  
  - [x] I have checked the [existing issues](https://github.com/Avaiga/taipy/issues?q=is%3Aissue+).
  - [x] I am willing to work on this issue (optional)