← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 889038] Re: Found Traceback When Install a Manufacturing

 

** Changed in: openobject-addons
       Status: Fix Committed => Fix Released

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

Title:
  Found Traceback When Install a Manufacturing

Status in OpenERP Addons (modules):
  Fix Released

Bug description:
  Problem : Found Traceback When Install a Manufacturing

  When i try to install MRP : A traceback Found Due to yml file
  Find out traceback
  ===================================================================
  Traceback (most recent call last):
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 740, in process
      self._process_node(node)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 777, in _process_node
      self.process_function(node)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 503, in process_function
      getattr(model, method)(self.cr, self.uid, *args)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 476, in run_scheduler
      self._procure_confirm(cr, uid, use_new_cursor=use_new_cursor, context=context)
    File "/home/amb/source/addons/trunk/procurement/schedulers.py", line 95, in _procure_confirm
      wf_service.trg_validate(uid, 'procurement.order', proc.id, 'button_check', cr)
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_service.py", line 124, in trg_validate
      res2 = instance.validate(cr, id, ident, signal)
    File "/home/amb/source/server/trunk/openerp/workflow/instance.py", line 48, in validate
      workitem.process(cr, witem, ident, signal, force_running, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 174, in _split_test
      _join_test(cr, t[0], t[1], ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 182, in _join_test
      create(cr,[activity], inst_id, ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 41, in create
      process(cr, res, ident, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 174, in _split_test
      _join_test(cr, t[0], t[1], ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 182, in _join_test
      create(cr,[activity], inst_id, ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 41, in create
      process(cr, res, ident, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 156, in _split_test
      if wkf_expr.check(cr, workitem, ident, transition,signal):
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_expr.py", line 81, in check
      return _eval_expr(cr, ident, workitem, transition['condition'])
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_expr.py", line 58, in _eval_expr
      ret = eval(line, env, nocopy=True)
    File "/home/amb/source/server/trunk/openerp/tools/safe_eval.py", line 286, in safe_eval
      return eval(test_expr(expr,_SAFE_OPCODES, mode=mode), globals_dict, locals_dict)
    File "", line 1, in <module>
    File "/home/amb/source/server/trunk/openerp/osv/orm.py", line 372, in function_proxy
      return attr(self._cr, self._uid, [self._id], *args, **kwargs)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 255, in check_make_to_stock
      ok = ok and self._check_make_to_stock_product(cr, uid, procurement, context)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 377, in _check_make_to_stock_product
      ok = ok and self.pool.get('stock.move').action_assign(cr, uid, [id])
    File "/home/amb/source/addons/trunk/stock/stock.py", line 1900, in action_assign
      res = self.check_assign(cr, uid, todo)
    File "/home/amb/source/addons/trunk/stock/stock.py", line 1945, in check_assign
      res = self.pool.get('stock.location')._product_reserve(cr, uid, [move.location_id.id], move.product_id.id, move.product_qty, {'uom': move.product_uom.id}, lock=True)
    File "/home/amb/source/addons/trunk/stock/stock.py", line 446, in _product_reserve
      amount = self.pool.get('product.uom')._compute_qty(cr, uid, r['product_uom'], r['product_qty'], context.get('uom', False))
    File "/home/amb/source/addons/trunk/product/product.py", line 136, in _compute_qty
      return self._compute_qty_obj(cr, uid, from_unit, qty, to_unit)
    File "/home/amb/source/addons/trunk/product/product.py", line 143, in _compute_qty_obj
      raise osv.except_osv(_('Error !'), _('Conversion from Product UoM %s to Default UoM %s is not possible as they both belong to different Category!.') % (from_unit.name,to_unit.name,))
  except_osv: ('Error !', u'Conversion from Product UoM cm to Default UoM PCE is not possible as they both belong to different Category!.')
  [2011-11-11 10:51:47,627][test_nov11] ERROR:init.test:Tests failed to execute in module mrp
  Traceback (most recent call last):
    File "/home/amb/source/server/trunk/openerp/modules/loading.py", line 100, in load_test
      _load_data(cr, module_name, idref, mode, 'test')
    File "/home/amb/source/server/trunk/openerp/modules/loading.py", line 135, in _load_data
      tools.convert_yaml_import(cr, module_name, fp, idref, mode, noupdate)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 805, in yaml_import
      yaml_interpreter.process(yaml_string)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 740, in process
      self._process_node(node)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 777, in _process_node
      self.process_function(node)
    File "/home/amb/source/server/trunk/openerp/tools/yaml_import.py", line 503, in process_function
      getattr(model, method)(self.cr, self.uid, *args)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 476, in run_scheduler
      self._procure_confirm(cr, uid, use_new_cursor=use_new_cursor, context=context)
    File "/home/amb/source/addons/trunk/procurement/schedulers.py", line 95, in _procure_confirm
      wf_service.trg_validate(uid, 'procurement.order', proc.id, 'button_check', cr)
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_service.py", line 124, in trg_validate
      res2 = instance.validate(cr, id, ident, signal)
    File "/home/amb/source/server/trunk/openerp/workflow/instance.py", line 48, in validate
      workitem.process(cr, witem, ident, signal, force_running, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 174, in _split_test
      _join_test(cr, t[0], t[1], ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 182, in _join_test
      create(cr,[activity], inst_id, ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 41, in create
      process(cr, res, ident, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 174, in _split_test
      _join_test(cr, t[0], t[1], ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 182, in _join_test
      create(cr,[activity], inst_id, ident, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 41, in create
      process(cr, res, ident, stack=stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 61, in process
      ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
    File "/home/amb/source/server/trunk/openerp/workflow/workitem.py", line 156, in _split_test
      if wkf_expr.check(cr, workitem, ident, transition,signal):
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_expr.py", line 81, in check
      return _eval_expr(cr, ident, workitem, transition['condition'])
    File "/home/amb/source/server/trunk/openerp/workflow/wkf_expr.py", line 58, in _eval_expr
      ret = eval(line, env, nocopy=True)
    File "/home/amb/source/server/trunk/openerp/tools/safe_eval.py", line 286, in safe_eval
      return eval(test_expr(expr,_SAFE_OPCODES, mode=mode), globals_dict, locals_dict)
    File "", line 1, in <module>
    File "/home/amb/source/server/trunk/openerp/osv/orm.py", line 372, in function_proxy
      return attr(self._cr, self._uid, [self._id], *args, **kwargs)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 255, in check_make_to_stock
      ok = ok and self._check_make_to_stock_product(cr, uid, procurement, context)
    File "/home/amb/source/addons/trunk/procurement/procurement.py", line 377, in _check_make_to_stock_product
      ok = ok and self.pool.get('stock.move').action_assign(cr, uid, [id])
    File "/home/amb/source/addons/trunk/stock/stock.py", line 1900, in action_assign
      res = self.check_assign(cr, uid, todo)
    File "/home/amb/source/addons/trunk/stock/stock.py", line 1945, in check_assign
      res = self.pool.get('stock.location')._product_reserve(cr, uid, [move.location_id.id], move.product_id.id, move.product_qty, {'uom': move.product_uom.id}, lock=True)
    File "/home/amb/source/addons/trunk/stock/stock.py", line 446, in _product_reserve
      amount = self.pool.get('product.uom')._compute_qty(cr, uid, r['product_uom'], r['product_qty'], context.get('uom', False))
    File "/home/amb/source/addons/trunk/product/product.py", line 136, in _compute_qty
      return self._compute_qty_obj(cr, uid, from_unit, qty, to_unit)
    File "/home/amb/source/addons/trunk/product/product.py", line 143, in _compute_qty_obj
      raise osv.except_osv(_('Error !'), _('Conversion from Product UoM %s to Default UoM %s is not possible as they both belong to different Category!.') % (from_unit.name,to_unit.name,))
  except_osv: ('Error !', u'Conversion from Product UoM cm to Default UoM PCE is not possible as they both belong to different Category!.')
  ==================================================================

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/889038/+subscriptions


References