← Back to team overview

banking-addons-team team mailing list archive

[Bug 1306957] [NEW] Import from Triodos bank fails 'partner' referenced before assignment

 

Public bug reported:

When trying to import a bank file from our triodos bank we get this
error.

Server Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/openerp/addons/web/session.py", line 89, in send
    return openerp.netsvc.dispatch_rpc(service_name, method, args)
  File "/usr/lib/pymodules/python2.7/openerp/netsvc.py", line 296, in dispatch_rpc
    result = ExportService.getService(service_name).dispatch(method, params)
  File "/usr/lib/pymodules/python2.7/openerp/service/web_services.py", line 626, in dispatch
    res = fn(db, uid, *params)
  File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 190, in execute_kw
    return self.execute(db, uid, obj, method, *args, **kw or {})
  File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 132, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 199, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 187, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/wizard/bank_import.py", line 311, in import_statements_file
    import_transaction_obj.match(cr, uid, transaction_ids, results=results, context=context)
  File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/banking_import_transaction.py", line 1043, in match
    results['log']
  File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/banking_import_transaction.py", line 94, in _match_costs
    cr, uid, [account_info.bank_partner_id.id], ['invoice']
  File "/usr/lib/pymodules/python2.7/openerp/addons/base/res/res_partner.py", line 721, in address_get
    default = result.get('default', partner.id)
UnboundLocalError: local variable 'partner' referenced before assignment

Any help or pointers would be appreciated.

** Affects: banking-addons
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Banking
Addons Core Editors, which is subscribed to Banking Addons.
https://bugs.launchpad.net/bugs/1306957

Title:
  Import from Triodos bank fails 'partner' referenced before assignment

Status in OpenERP Banking Addons:
  New

Bug description:
  When trying to import a bank file from our triodos bank we get this
  error.

  Server Traceback (most recent call last):
    File "/usr/lib/pymodules/python2.7/openerp/addons/web/session.py", line 89, in send
      return openerp.netsvc.dispatch_rpc(service_name, method, args)
    File "/usr/lib/pymodules/python2.7/openerp/netsvc.py", line 296, in dispatch_rpc
      result = ExportService.getService(service_name).dispatch(method, params)
    File "/usr/lib/pymodules/python2.7/openerp/service/web_services.py", line 626, in dispatch
      res = fn(db, uid, *params)
    File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 190, in execute_kw
      return self.execute(db, uid, obj, method, *args, **kw or {})
    File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 132, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 199, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/usr/lib/pymodules/python2.7/openerp/osv/osv.py", line 187, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/wizard/bank_import.py", line 311, in import_statements_file
      import_transaction_obj.match(cr, uid, transaction_ids, results=results, context=context)
    File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/banking_import_transaction.py", line 1043, in match
      results['log']
    File "/usr/lib/pymodules/python2.7/openerp/addons/account_banking/banking_import_transaction.py", line 94, in _match_costs
      cr, uid, [account_info.bank_partner_id.id], ['invoice']
    File "/usr/lib/pymodules/python2.7/openerp/addons/base/res/res_partner.py", line 721, in address_get
      default = result.get('default', partner.id)
  UnboundLocalError: local variable 'partner' referenced before assignment

  Any help or pointers would be appreciated.

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


Follow ups

References