← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 708603] Re: Miscalculation of parent_store data when moving multiple records under same parent

 

The fix has landed in 6.0 and was ported to trunk as well:
- 6.0: rev 3334 odo@xxxxxxxxxxx-20110203225102-a7v8bv90l2ph5ujh
- trunk: rev 3342 odo@xxxxxxxxxxx-20110203230023-o2a0b5tovewu0ft2

I'm adding a bug task for 5.0 as well, in order for maintenance team to
evaluate whether this should be backported to 5.0. I think it's very
low-risk and quite important... and that code has not changed much since
5.0...

** Changed in: openobject-server
   Importance: Medium => High

** Changed in: openobject-server
       Status: Confirmed => Fix Released

** Changed in: openobject-server
    Milestone: None => 6.0.2

** Also affects: openobject-server/5.0
   Importance: Undecided
       Status: New

** Changed in: openobject-server/5.0
   Importance: Undecided => High

** Changed in: openobject-server/5.0
       Status: New => Confirmed

** Changed in: openobject-server/5.0
    Milestone: None => 5.0.16

** Changed in: openobject-server/5.0
     Assignee: (unassigned) => Jay Vora (OpenERP) (jvo-openerp)

** Tags added: maintenance

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/708603

Title:
  Miscalculation of parent_store data when moving multiple records under
  same parent

Status in OpenERP Server:
  Fix Released
Status in OpenERP Server 5.0 series:
  Confirmed

Bug description:
  
  When i duplicate a account to ctrl+shift+d i found this traceback on server side.

  [2011-01-27 17:40:25,970][db_trunk_inv] ERROR:web-services:Uncaught exception
  Traceback (most recent call last):
    File "/home/tiny/workspace/openobject-server/bin/osv/osv.py", line 122, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/home/tiny/workspace/openobject-server/bin/osv/osv.py", line 176, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/home/tiny/workspace/openobject-server/bin/osv/osv.py", line 167, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/home/tiny/workspace/openobject-addons/account/account.py", line 495, in copy
      child_ids = self.copy(cr, uid, child.id, default, context=context, done_list=done_list, local=True)
    File "/home/tiny/workspace/openobject-addons/account/account.py", line 495, in copy
      child_ids = self.copy(cr, uid, child.id, default, context=context, done_list=done_list, local=True)
    File "/home/tiny/workspace/openobject-addons/account/account.py", line 501, in copy
      return super(account_account, self).copy(cr, uid, id, default, context=context)
    File "/home/tiny/workspace/openobject-server/bin/osv/orm.py", line 4145, in copy
      data = self.copy_data(cr, uid, id, default, context)
    File "/home/tiny/workspace/openobject-server/bin/osv/orm.py", line 4031, in copy_data
      data = self.read(cr, uid, [id,], context=context_wo_lang)
    File "/home/tiny/workspace/openobject-server/bin/osv/orm.py", line 2921, in read
      result = self._read_flat(cr, user, select, fields, context, load)
    File "/home/tiny/workspace/openobject-server/bin/osv/orm.py", line 3032, in _read_flat
      res2 = self._columns[val[0]].get(cr, self, ids, val, user, context=context, values=res)
    File "/home/tiny/workspace/openobject-server/bin/osv/fields.py", line 793, in get
      res = self._fnct(obj, cr, user, ids, name, self._arg, context)
    File "/home/tiny/workspace/openobject-addons/account/account.py", line 305, in __compute
      sums[current.id][fn] += sums[child.id][fn]

  It took more number of digits then actual in account code.

  Thanks





References