- changed status to resolved
potential bug in fire_replace_event of attributes.py
Issue #925
resolved
def fire_replace_event(self, state, value, previous, initiator):
if self.key not in state.committed_state:
state.committed_state[self.key](self.key) = previous
state.modified = True
if self.trackparent:
if value is not None:
self.sethasparent(value._state, True)
if previous is not None:
self.sethasparent(previous._state, False)
instance = state.obj()
for ext in self.extensions:
ext.set(instance, value, previous, initiator or self)
examine the above code:
if value == previous, sethasparent would reset the state to False
Lei
Comments (2)
-
repo owner -
repo owner - removed milestone
Removing milestone: 0.4.xx (automated comment)
- Log in to comment
it was a real bug, you can view two previously failing test cases in e8feacf1db658ecccf7bb1d1688662e701ad37f5. thanks !