Turns out my new code had an unnecessary self.save() inside a scan in a beforeSave() hook. While this redundancy seemed to work prior to dabo r6425, I think it was a mistake to do and thus, I don't think we need to fix anything having to do with r6425.
I assumed it was Dabo's fault simply because of an artifact of my testing methodology: + revert back to last known good dabo version - works: regression test dabo - doesn't work: regression test my code So I never got to regression testing my own code, even though that would have pointed to my error much sooner, since it was right there in one of the final lines of the traceback: > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 282, in scanfunc > self.Record.is_default = False Paul On 3/30/11 3:48 PM, Paul McNett wrote: > In r6425: > ------------------------------------------------------------------------ > r6425 | JacekK | 2011-02-11 10:39:59 -0800 (Fri, 11 Feb 2011) | 1 line > Changed paths: > M /trunk/dabo/biz/dBizobj.py > > Optimizing children cursors requery for non matching FK. > ------------------------------------------------------------------------ > > I'm seeing this error, upon saving one of my bizobjs from the UI: > > Traceback (most recent call last): > File "/home/pmcnett/dabo-full/trunk/dabo/ui/uiwx/dMenuItem.py", line 58, > in __onWxHit > self.raiseEvent(dEvents.Hit, evt) > File "/home/pmcnett/dabo-full/trunk/dabo/ui/uiwx/dPemMixin.py", line > 1007, in > raiseEvent > super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args, > **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/lib/eventMixin.py", line 96, in > raiseEvent > bindingFunction(event) > File "/home/pmcnett/dabo-full/trunk/dabo/ui/uiwx/dForm.py", line 712, in > onSave > def onSave(self, evt): self.save() > File "/home/pmcnett/dabo-full/trunk/dabo/lib/datanav/Form.py", line 66, > in save > ret = super(Form, self).save(dataSource) > File "/home/pmcnett/dabo-full/trunk/dabo/ui/uiwx/dForm.py", line 386, in > save > bizobj.saveAll() > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 402, in > saveAll > startTransaction=False) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 854, in > scanChangedRows > func(*args, **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 463, in > save > self._onSaveNew() > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 1447, in > _onSaveNew > self.onSaveNew() > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/customers.py", > line 101, in onSaveNew > self.save() > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 470, in > save > child.saveAll(startTransaction=False) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 402, in > saveAll > startTransaction=False) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 854, in > scanChangedRows > func(*args, **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 443, in > save > errMsg = self.beforeSave() > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 284, in beforeSave > self.scan(scanfunc) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 762, in > scan > self.scanRows(func, range(self.RowCount), *args, **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 810, in > scanRows > func(*args, **kwargs) > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 283, in scanfunc > self.save() > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 443, in > save > errMsg = self.beforeSave() > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 284, in beforeSave > self.scan(scanfunc) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 762, in > scan > self.scanRows(func, range(self.RowCount), *args, **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 810, in > scanRows > func(*args, **kwargs) > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 283, in scanfunc > self.save() > > ---snipped hundreds of recursive lines--- > > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 443, in > save > errMsg = self.beforeSave() > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 284, in beforeSave > self.scan(scanfunc) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 762, in > scan > self.scanRows(func, range(self.RowCount), *args, **kwargs) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 810, in > scanRows > func(*args, **kwargs) > File > "/Users/pmcnett/py/sbs/shutter_studio/trunk/clients/shutter_studio/biz/productlines.py", > line 282, in scanfunc > self.Record.is_default = False > File "/home/pmcnett/dabo-full/trunk/dabo/db/__init__.py", line 102, in > __setattr__ > self._cursor.setFieldVal(att, val) > File "/home/pmcnett/dabo-full/trunk/dabo/biz/dBizobj.py", line 1665, in > setFieldVal > changed = self._CurrentCursor.setFieldVal(fld, val, row, pk) > File "/home/pmcnett/dabo-full/trunk/dabo/db/dCursorMixin.py", line 984, > in setFieldVal > fldType = self._fldTypeFromDB(fld) > File "/home/pmcnett/dabo-full/trunk/dabo/db/dCursorMixin.py", line 920, in > _fldTypeFromDB > flds = self.getFields() > File "/home/pmcnett/dabo-full/trunk/dabo/db/dCursorMixin.py", line 2114, > in getFields > key = "%s:::%s" % (tableName, self.CurrentSQL) > File "/home/pmcnett/dabo-full/trunk/dabo/db/dCursorMixin.py", line 2565, > in > _getCurrentSQL > if self.UserSQL: > RuntimeError: maximum recursion depth exceeded while calling a Python object > > Paul > [excessive quoting removed by server] _______________________________________________ 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]
