On 1/26/10 4:13 PM, Jacek Kałucki wrote: > Użytkownik Paul McNett napisał: >> I added a test to dabo/biz/test/test_dBizobj.py for the case you describe, >> but don't >> see any infinite loop. See r5604. >> > > Lets assume we have child with one or few records: > 1) remote user delete _all_ child records from backend but not parent > 2) we still have this data on our machine > 3) we decide to delete parent record > 4) parent bizobj calls child.deleteAll() method with loop in code > 5) execute loop: > while self.RowCount> 0: > self.first() > self.delete(startTransaction=False, inLoop=True) > 6) in dCursorMixin.delete() method query is executed but code: > sql = "select count(*) as cnt from %s where %s" % (self.Table, > pkWhere) > returns 0 because all records were deleted before and aren't existing > 7) code: > self._removeRow(delRowNum) > isn't executed so RowCount doesn't change > 8) go to point 5
I missed the "remote user" significance before. Paul _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev Searchable Archives: http://leafe.com/archives/search/dabo-dev This message: http://leafe.com/archives/byMID/[email protected]
