Repeating Panel Attributes changed in refreshing_data_binding event not captured

What I’m trying to do:

I have a repeating panel with certain attributes defined in the init method. When the items of that repeating panel are set, I also change some of those attributes.

What I’ve tried and what’s not working:

Those attributes that are changed, are not saved. when updated via the refreshing_data_bindings event, but will save if changed in a for loop using get_components

Code Sample:

Here is the RowTemplate

class RowTemplate1(RowTemplate1Template):
  def __init__(self, **properties):
    # Set Form properties and Data Bindings.

    # Any code you write here will run before the form opens.
    self.quantity = 0
    self.value    = None

  def reset_quantity(self):
    self.quantity = 1
    print(f"Quantity set to {self.quantity}")

  def set_value(self,value):
    self.value = value

  def form_refreshing_data_bindings(self, **event_args):
    """This method is called when refreshing_data_bindings is called"""

This will change quantity permanently

for comp in self.repeating_panel_1.get_components():

This is what I want to work but does not

Note: the print statement in reset_quantity will still print

self.repeating_panel_1.items = items # set items to raise  `refreshing_data_bindings` event

Clone link:
share a copy of your app