← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 723641] Re: [V5.0.15] mrp Scheduler : crash if no Reservation

 

Hello,

If I start with a new DB it's work but If I use an old DB it crash.
I have made an other test, I have create a procurement from scratch, on the newly create database it's work, I can remove the Reservation without error.
but on the updated database I can't, I have paste the traceback and you will find the update database attached


[2011-02-23 16:38:22,849][v5_20100216] INFO:init:module profile_service: loading profile_service.xml
[2011-02-23 16:38:22,901][v5_20100216] INFO:init:Deleting 463@ir.values
[2011-02-23 16:38:22,909][v5_20100216] WARNING:init:Not all modules have loaded.
[2011-02-23 16:38:22,910][v5_20100216] WARNING:init:object report.closed.task (Closed Task Report) has no access rules!
[2011-02-23 16:38:22,910][v5_20100216] WARNING:init:object report.timesheet.task.user (report.timesheet.task.user) has no access rules!
[2011-02-23 16:38:23,054][v5_20100216] INFO:init:[01]: Assertions report:
[2011-02-23 16:38:23,054][v5_20100216] INFO:init:[02]: Level	success	failed
[2011-02-23 16:38:23,054][v5_20100216] INFO:init:[03]: error	1	0
[2011-02-23 16:38:23,054][v5_20100216] INFO:init:[04]: total	1	0
[2011-02-23 16:38:23,054][v5_20100216] INFO:init:[05]: end of report (1 assertion(s) checked)
/home/vrenaville/tmpinstance/5Uptodate/server/bin/tools/misc.py:749: DeprecationWarning: BaseException.message has been deprecated as of Python 2.6
  if hasattr(e, 'message'):
/home/vrenaville/tmpinstance/5Uptodate/server/bin/tools/misc.py:750: DeprecationWarning: BaseException.message has been deprecated as of Python 2.6
  return ustr(e.message)
Exception in thread Thread-129:
Traceback (most recent call last):
  File "/usr/lib/python2.6/threading.py", line 532, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.6/threading.py", line 484, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/addons/mrp/wizard/wizard_schedulers_all.py", line 42, in _procure_calculation_all
    context=context)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/addons/mrp/mrp.py", line 1130, in run_scheduler
    self._procure_confirm(cr, uid, use_new_cursor=use_new_cursor, context=context)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/addons/mrp/schedulers.py", line 65, in _procure_confirm
    wf_service.trg_validate(uid, 'mrp.procurement', proc.id, 'button_check', cr)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/wkf_service.py", line 81, in trg_validate
    res2 = instance.validate(cr, id, ident, signal)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/instance.py", line 50, in validate
    workitem.process(cr, witem, ident, signal, force_running, stack=stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 62, in process
    ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 175, in _split_test
    _join_test(cr, t[0], t[1], ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 183, in _join_test
    create(cr,[activity], inst_id, ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 42, in create
    process(cr, res, ident, stack=stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 62, in process
    ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 175, in _split_test
    _join_test(cr, t[0], t[1], ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 183, in _join_test
    create(cr,[activity], inst_id, ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 42, in create
    process(cr, res, ident, stack=stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 62, in process
    ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 175, in _split_test
    _join_test(cr, t[0], t[1], ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 183, in _join_test
    create(cr,[activity], inst_id, ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 42, in create
    process(cr, res, ident, stack=stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 62, in process
    ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 175, in _split_test
    _join_test(cr, t[0], t[1], ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 183, in _join_test
    create(cr,[activity], inst_id, ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 42, in create
    process(cr, res, ident, stack=stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 54, in process
    result = _execute(cr, workitem, activity, ident, stack)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/workitem.py", line 127, in _execute
    id_new = wkf_expr.execute(cr, ident, workitem, activity)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/wkf_expr.py", line 69, in execute
    return _eval_expr(cr, ident, workitem, activity['action'])
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/workflow/wkf_expr.py", line 59, in _eval_expr
    ret = eval(line, env, nocopy=True)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/tools/safe_eval.py", line 274, in safe_eval
    return eval(test_expr(expr,_SAFE_OPCODES, mode=mode), globals_dict, locals_dict)
  File "", line 1, in <module>
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/osv/orm.py", line 168, in <lambda>
    return lambda *args, **argv: getattr(self._table, name)(self._cr, self._uid, [self._id], *args, **argv)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/addons/mrp/mrp.py", line 1020, in action_produce_assign_product
    {'location_id':procurement.location_id.id})
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/osv/orm.py", line 2650, in write
    cr.execute(select_query, (tuple(sub_ids),))
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/sql_db.py", line 78, in wrapper
    return f(self, *args, **kwargs)
  File "/home/vrenaville/tmpinstance/5Uptodate/server/bin/sql_db.py", line 123, in execute
    res = self._obj.execute(query, params)
ProgrammingError: operator does not exist: integer = boolean
LINE 1: SELECT id FROM "stock_move"  WHERE id IN (false)
                                              ^
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.

Thanks for your help,

Vincent

-- 
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/723641

Title:
  [V5.0.15] mrp Scheduler : crash if no Reservation

Status in OpenERP Modules (addons):
  Incomplete

Bug description:
  Hello,

  We have a problem with Procurement :

  If you create a sale order, this sale order create a procurement.
  You edit the created procurement, you confirm the procurement
  after that you go to the "Extra Information" tab and you remove the Reservation

  In this case if you run the Scheduler, it will crash because you have no Reservation on one procurement.
  but the user is not warn about it.

  The Scheduler must warn the user that some procurements fails due to
  user error and list them.

  
  Thanks for your help,

  
  Vincent



References