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.

1

Element '<tree string="My view">' not found in parent view 'base.view_users_form' [Closed]

By
priyankahdp
on 4/16/13, 4:48 AM 1,828 views

The Question has been closed

by
Sudhir Arya (SA)
on 04/18/2013 05:09:27

when i trying to add users menu to mu module and going to use inherit its form view then below error occured.please advice me to sort this issue. my whole source code uploaded here@GitHub

AttributeError: View definition error for inherited view 'bpl.view_users_inherit_form' on model 'res.users': Element '<tree string="My view">' not found in parent view 'base.view_users_form'

below shows whole error in my eclipse console

2013-04-16 06:44:21,114 2922 INFO bellvantage openerp.modules.loading: loading 1 modules...
2013-04-16 06:44:21,250 2922 INFO bellvantage openerp.modules.loading: loading 33 modules...
2013-04-16 06:44:21,343 2922 INFO bellvantage openerp.modules.module: module bpl: creating or updating database tables
2013-04-16 06:44:22,095 2922 INFO bellvantage openerp.modules.loading: module bpl: loading bpl_worker_registration_sequence.xml
2013-04-16 06:44:22,104 2922 INFO bellvantage openerp.modules.loading: module bpl: loading bpl_view.xml
2013-04-16 06:44:22,613 2922 WARNING bellvantage openerp.addons.base.ir.ir_ui_view: Setting the `type` field is deprecated in the `ir.ui.view` model.
2013-04-16 06:44:23,445 2922 INFO bellvantage openerp.modules.loading: module bpl: loading security/bpl_security.xml
2013-04-16 06:44:23,532 2922 ERROR bellvantage openerp.addons.base.ir.ir_ui_view: Can't render view base.user_groups_view for model: res.users
Traceback (most recent call last):
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/ir/ir_ui_view.py", line 125, 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 "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 2235, in fields_view_get
    arch=apply_view_inheritance(cr, user, source, sql_res['id']),
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 2193, in apply_view_inheritance
    source = apply_inheritance_specs(source, view_arch, view_id)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 2177, in apply_inheritance_specs
    raise_view_error("Element '%s' not found in parent view '%%(parent_xml_id)s'" % tag, inherit_id)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 2070, in raise_view_error
    %  (child_view.xml_id, self._name, error_msg))
AttributeError: View definition error for inherited view 'bpl.view_users_inherit_form' on model 'res.users': Element '<tree string="My view">' not found in parent view 'base.view_users_form'
2013-04-16 06:44:23,534 2922 ERROR bellvantage openerp.tools.convert: Parse error in /home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/bpl/security/bpl_security.xml:9: 
<record id="group_checkroll_user" model="res.groups">
            <field name="name">Checkroll_User</field>
            <field name="category_id" ref="module_checkroll_category"/>
        </record>
Traceback (most recent call last):
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/tools/convert.py", line 847, in parse
    self._tags[rec.tag](self.cr, rec, n)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/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.isnoupdate(data_node), mode=self.mode, context=rec_context )
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/ir/ir_model.py", line 937, in _update
    model_obj.write(cr, uid, [res_id], values, context=context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/mail/res_users.py", line 190, in write
    write_res = super(res_groups_mail_group, self).write(cr, uid, ids, vals, context=context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/res/res_users.py", line 660, in write
    self.update_user_groups_view(cr, uid, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/res/res_users.py", line 694, in update_user_groups_view
    view.write({'arch': xml_content})
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 374, in function_proxy
    return attr(self._cr, self._uid, [self._id], *args, **kwargs)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/ir/ir_ui_view.py", line 207, in write
    return super(view, self).write(cr, uid, ids, vals, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 4201, in write
    self._validate(cr, user, ids, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 1544, in _validate
    raise except_orm('ValidateError', '\n'.join(error_msgs))
except_orm: ('ValidateError', u'Error occurred while validating the field(s) arch: Invalid XML for View Architecture!')
2013-04-16 06:44:23,535 2922 ERROR bellvantage openerp.netsvc: ValidateError
Error occurred while validating the field(s) arch: Invalid XML for View Architecture!
Traceback (most recent call last):
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/netsvc.py", line 293, in dispatch_rpc
    result = ExportService.getService(service_name).dispatch(method, params)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/service/web_services.py", line 614, in dispatch
    security.check(db,uid,passwd)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/service/security.py", line 40, in check
    pool = pooler.get_pool(db)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/pooler.py", line 49, in get_pool
    return get_db_and_pool(db_name, force_demo, status, update_module)[1]
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/pooler.py", line 33, in get_db_and_pool
    registry = RegistryManager.get(db_name, force_demo, status, update_module)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/registry.py", line 192, in get
    update_module)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/registry.py", line 218, in new
    openerp.modules.load_modules(registry.db, force_demo, status, update_module)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/loading.py", line 344, in load_modules
    processed = load_marked_modules(cr, graph, states_to_load, force, status, report, loaded_modules, update_module)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/loading.py", line 259, in load_marked_modules
    loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/loading.py", line 191, in load_module_graph
    load_data(module_name, idref, mode)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/loading.py", line 76, in <lambda>
    load_data = lambda *args: _load_data(cr, *args, kind='data')
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/modules/loading.py", line 127, in _load_data
    tools.convert_xml_import(cr, module_name, fp, idref, mode, noupdate, report)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/tools/convert.py", line 954, in convert_xml_import
    obj.parse(doc.getroot())
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/tools/convert.py", line 847, in parse
    self._tags[rec.tag](self.cr, rec, n)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/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.isnoupdate(data_node), mode=self.mode, context=rec_context )
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/ir/ir_model.py", line 937, in _update
    model_obj.write(cr, uid, [res_id], values, context=context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/mail/res_users.py", line 190, in write
    write_res = super(res_groups_mail_group, self).write(cr, uid, ids, vals, context=context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/res/res_users.py", line 660, in write
    self.update_user_groups_view(cr, uid, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/res/res_users.py", line 694, in update_user_groups_view
    view.write({'arch': xml_content})
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 374, in function_proxy
    return attr(self._cr, self._uid, [self._id], *args, **kwargs)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/addons/base/ir/ir_ui_view.py", line 207, in write
    return super(view, self).write(cr, uid, ids, vals, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 4201, in write
    self._validate(cr, user, ids, context)
  File "/home/bellvantage/Documents/openerp-7.0/openerp-7/openerp/osv/orm.py", line 1544, in _validate
    raise except_orm('ValidateError', '\n'.join(error_msgs))
except_orm: ('ValidateError', u'Error occurred while validating the field(s) arch: Invalid XML for View Architecture!')
2013-04-16 06:44:23,540 2922 INFO bellvantage werkzeug: 127.0.0.1 - - [16/Apr/2013 06:44:23] "POST /web/dataset/call_button HTTP/1.1" 200 -
2

Sudhir Arya (SA)

--Sudhir Arya (SA)--
10150
| 6 8 8
Ahmedabad, India
--Sudhir Arya (SA)--

Working as an OpenERP/Odoo developer and a Team Leader 

Top 5 Odoo contributor On Stackoverflow

LinkedIn

Blog

Stackoverflow

Sudhir Arya (SA)
On 4/16/13, 5:07 AM

I think problem is at line 804 in bpl_view.xml:

<record model="ir.ui.view" id="view_users_inherit_form">
    <field name="name">res.users.form.inherit</field>
    <field name="inherit_id" ref="base.view_users_form" />
    <field name="model">res.users</field>
    <field name="type">form</field>
</record>

Remove this view and update your module.

Hope error will be resolved by this.

Thanks arya now issue sorted. :-) but what is the reason for that.? i need to inherit users form view.then how to do that.?

priyankahdp
on 4/16/13, 5:26 AM

About This Community

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

Question tools

0 follower(s)

Stats

Asked: 4/16/13, 4:48 AM
Seen: 1828 times
Last updated: 3/16/15, 8:10 AM