[6.1] TypeError: 'NoneType' object is not iterable

Bug #1087847 reported by Maxime Chambreuil (http://www.savoirfairelinux.com)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenERP Canada
Fix Released
Undecided
Joao Alfredo Gama Batista
6.1
Fix Released
Undecided
Unassigned

Bug Description

On 6.1,

* install hr_expense_line_supplier and account_tax_expense_included
* Check included in expense on a tax
* Create an expense sheet line with a product using the previous tax
* Confirm and approve the expense sheet
* Generate the invoice

I get:

Server Traceback (most recent call last):
  File "/home/max/openerp/web/6.1/addons/web/common/http.py", line 593, in send
    return openerp.netsvc.dispatch_rpc(service_name, method, args)
  File "/home/max/openerp/server/6.1/openerp/netsvc.py", line 360, in dispatch_rpc
    result = ExportService.getService(service_name).dispatch(method, params)
  File "/home/max/openerp/server/6.1/openerp/service/web_services.py", line 586, in dispatch
    res = fn(db, uid, *params)
  File "/home/max/openerp/server/6.1/openerp/osv/osv.py", line 167, in execute_kw
    return self.execute(db, uid, obj, method, *args, **kw or {})
  File "/home/max/openerp/server/6.1/openerp/osv/osv.py", line 121, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/max/openerp/server/6.1/openerp/osv/osv.py", line 176, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/max/openerp/addons/6.1/audittrail/audittrail.py", line 495, in execute_cr
    return fct_src(cr, uid, model, method, *args)
  File "/home/max/openerp/server/6.1/openerp/osv/osv.py", line 164, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/max/openerp/addons/6.1/hr_expense/hr_expense.py", line 138, in invoice
    wf_service.trg_validate(uid, 'hr.expense.expense', id, 'invoice', cr)
  File "/home/max/openerp/server/6.1/openerp/workflow/wkf_service.py", line 124, in trg_validate
    res2 = instance.validate(cr, id, ident, signal)
  File "/home/max/openerp/server/6.1/openerp/workflow/instance.py", line 48, in validate
    workitem.process(cr, witem, ident, signal, force_running, stack=stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 61, in process
    ok = _split_test(cr, workitem, activity['split_mode'], ident, signal, stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 176, in _split_test
    _join_test(cr, t[0], t[1], ident, stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 184, in _join_test
    create(cr,[activity], inst_id, ident, stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 41, in create
    process(cr, res, ident, stack=stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 53, in process
    result = _execute(cr, workitem, activity, ident, stack)
  File "/home/max/openerp/server/6.1/openerp/workflow/workitem.py", line 128, in _execute
    id_new = wkf_expr.execute(cr, ident, workitem, activity)
  File "/home/max/openerp/server/6.1/openerp/workflow/wkf_expr.py", line 68, in execute
    return _eval_expr(cr, ident, workitem, activity['action'])
  File "/home/max/openerp/server/6.1/openerp/workflow/wkf_expr.py", line 58, in _eval_expr
    ret = eval(line, env, nocopy=True)
  File "/home/max/openerp/server/6.1/openerp/tools/safe_eval.py", line 241, in safe_eval
    return eval(test_expr(expr,_SAFE_OPCODES, mode=mode), globals_dict, locals_dict)
  File "", line 1, in <module>
  File "/home/max/openerp/server/6.1/openerp/osv/orm.py", line 368, in function_proxy
    return attr(self._cr, self._uid, [self._id], *args, **kwargs)
  File "/home/max/openerp/canada/6.1/hr_expense_line_supplier/hr_expense_line_supplier.py", line 56, in action_invoice_create
    for i in l.partner_id.property_account_position.tax_ids:
TypeError: 'NoneType' object is not iterable

Tags: 6.1
Changed in openerp-canada:
status: New → In Progress
Changed in openerp-canada:
status: In Progress → Fix Committed
Changed in openerp-canada:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.