← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 789658] Re: Impossible to create tax of type 'balance' through chart of accounts

 

** Changed in: openobject-addons
    Milestone: None => 6.1

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

Title:
  Impossible to create tax of type 'balance' through chart of accounts

Status in OpenERP Modules (addons):
  Fix Committed

Bug description:
  If you wanted to create a chart of accounts module that would create some 'account.tax' of type 'balance', you can't because 'account.tax.template' doesn't have 'balance' as possible value of 'type': http://bazaar.launchpad.net/~openerp/openobject-addons/6.0/view/4610/account/account.py#L2456
  while 'account.tax' has it: http://bazaar.launchpad.net/~openerp/openobject-addons/6.0/view/4610/account/account.py#L1685

  So, while installing such a module (try this if needed:
  http://bazaar.launchpad.net/~openobject-italia-core-devs/openobject-
  italia/l10n_it_fix_partially_deductible_vat/files/4610/l10n_it/ ),
  you'll get

  [2011-05-28 21:21:30,955][test] INFO:init:module l10n_it: loading data/account.tax.template.csv
  [2011-05-28 21:21:31,242][test] WARNING:import:key 'balance' not found in selection field 'type'
  [2011-05-28 21:21:31,256][test] ERROR:web-services:Uncaught exception
  Traceback (most recent call last):
    File "/home/elbati/workspace/openerp/openerp6/server/bin/osv/osv.py", line 122, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/osv/osv.py", line 176, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/osv/osv.py", line 167, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/base/res/res_config.py", line 167, in action_next
      next = self.execute(cr, uid, ids, context=None)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/account/installer.py", line 571, in execute
      super(account_installer, self).execute(cr, uid, ids, context=context)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/base/res/res_config.py", line 397, in execute
      new_db, self.pool = pooler.restart_pool(cr.dbname, update_module=True)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/pooler.py", line 60, in restart_pool
      return get_db_and_pool(db_name, force_demo, status, update_module=update_module)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/pooler.py", line 39, in get_db_and_pool
      addons.load_modules(db, force_demo, status, update_module)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/__init__.py", line 883, in load_modules
      processed_modules.extend(load_module_graph(cr, graph, status, report=report, skip_modules=processed_modules))
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/__init__.py", line 748, in load_module_graph
      load_init_update_xml(cr, m, idref, mode, kind)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/addons/__init__.py", line 635, in load_init_update_xml
      tools.convert_csv_import(cr, m, os.path.basename(filename), fp.read(), idref, mode=mode, noupdate=noupdate)
    File "/home/elbati/workspace/openerp/openerp6/server/bin/tools/convert.py", line 950, in convert_csv_import
      raise Exception(_('Module loading failed: file %s/%s could not be processed:\n %s') % (module, fname, warning_msg))
  Exception: Module loading failed: file l10n_it/account.tax.template.csv could not be processed:
   Line 6 : Key/value 'balance' not found in selection field 'type'


References