Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

AttributeError account_analytic_id not found

By
Renzo Meister
on 9/7/13, 12:30 PM 1,148 views

Hi all...

If have tried to update our OpenERP v7 from 20130302 release to the current 20130906 version. One of the databases would be updated without any problems. But another one using analytic plans will throw the following error when updating:

2013-09-07 14:06:15,010 2306 ERROR jamotion_prod openerp.addons.base.ir.ir_ui_view: Can't render view for model: account.invoice.line Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/base/ir/ir_ui_view.py", line 126, in _check_render_view fvg = self.pool.get(view.model).fields_view_get(cr, uid, view_id=view.id, view_type=view.type, context=context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/account/account_invoice.py", line 1453, in fields_view_get res = super(account_invoice_line,self).fields_view_get(cr, uid, view_id=view_id, view_type=view_type, context=context, toolbar=toolbar, submenu=submenu) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 2237, in fields_view_get arch=apply_view_inheritance(cr, user, source, sql_res['id']), File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 2195, in apply_view_inheritance source = apply_inheritance_specs(source, view_arch, view_id) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 2179, in apply_inheritance_specs raise_view_error("Element '%s' not found in parent view '%%(parent_xml_id)s'" % tag, inherit_id) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 2072, in raise_view_error % (child_view.xml_id, self._name, error_msg)) AttributeError: View definition error for inherited view 'account_analytic_plans.view_invoice_line_form_inherit' on model 'account.invoice.line': Element '<field name="account_analytic_id">' not found in parent view 'account.view_invoice_line_form' 2013-09-07 14:06:15,014 2306 ERROR jamotion_prod openerp.tools.convert: Parse error in /usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.e gg/openerp/addons/sale_analytic_plans/sale_analytic_plans_view.xml:44: <record model="ir.ui.view" id="view_invoice_line_form_inherit"> <field name="name">account.invoice.line.form.inherit</field> <field name="model">account.invoice.line</field> <field name="inherit_id" ref="account.view_invoice_line_form"/> <field name="arch" type="xml"> <field name="account_analytic_id" position="replace"> <field name="analytics_id" context="{'journal_id':parent.journal_id}" domain="[('plan_id','<>',False)]" groups="analytic.group_analytic_acc ounting"/> </field> </field> </record> Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/tools/convert.py", line 847, in parse self._tagsrec.tag File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/tools/convert.py", line 814, in _tag_record id = self.pool.get('ir.model.data')._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupd ate(data_node), mode=self.mode, context=rec_context ) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/base/ir/ir_model.py", line 964, in _update res_id = model_obj.create(cr, uid, values, context=context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/base/ir/ir_ui_view.py", line 103, in create return super(view, self).create(cr, uid, values, context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 4472, in create self._validate(cr, user, [id_new], context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 1546, in _validate raise except_orm('ValidateError', '\n'.join(error_msgs)) except_orm: ('ValidateError', u'Fehler w\xe4hrend der Pr\xfcfung des Feldes field(s) arch: Invalid XML for View Architecture!') 2013-09-07 14:06:15,015 2306 ERROR jamotion_prod openerp: Failed to initialize database jamotion_prod. Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/cli/server.py", line 97, in preload_registry db, registry = openerp.pooler.get_db_and_pool(dbname,update_module=update_module) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/pooler.py", line 33, in get_db_and_pool registry = RegistryManager.get(db_name, force_demo, status, update_module) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/registry.py", line 192, in get update_module) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/registry.py", line 218, in new openerp.modules.load_modules(registry.db, force_demo, status, update_module) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/loading.py", line 341, in load_modules processed = load_marked_modules(cr, graph, states_to_load, force, status, report, loaded_modules, update_module) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/loading.py", line 256, in load_marked_modules loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/loading.py", line 188, in load_module_graph load_data(module_name, idref, mode) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/loading.py", line 76, in <lambda> load_data = lambda *args: _load_data(cr, *args, kind='data') File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/modules/loading.py", line 124, in _load_data tools.convert_xml_import(cr, module_name, fp, idref, mode, noupdate, report) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/tools/convert.py", line 954, in convert_xml_import obj.parse(doc.getroot()) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/tools/convert.py", line 847, in parse self._tagsrec.tag File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/tools/convert.py", line 814, in _tag_record id = self.pool.get('ir.model.data')._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupd ate(data_node), mode=self.mode, context=rec_context ) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/base/ir/ir_model.py", line 964, in _update res_id = model_obj.create(cr, uid, values, context=context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/addons/base/ir/ir_ui_view.py", line 103, in create return super(view, self).create(cr, uid, values, context) File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 4472, in create self._validate(cr, user, [id_new], context) "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20130906_231030-py2.7.egg/openerp/osv/orm.py", line 1546, in _validate raise except_orm('ValidateError', '\n'.join(error_msgs)) except_orm: ('ValidateError', u'Fehler w\xe4hrend der Pr\xfcfung des Feldes field(s) arch: Invalid XML for View Architecture!')

I don't know how to fix this bug so any help would be very appreciated!!!

Best regards

Renzo Meister

Have you manually changed one of these views?

Andreas Brueckl
on 9/18/13, 12:21 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 9/7/13, 12:30 PM
Seen: 1148 times
Last updated: 3/16/15, 8:10 AM