Odoo Help


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.


('ValidateError', u'Error occurred while validating the field(s) arch: Invalid XML for View Architecture!')

Piyush Suva
on 10/18/14, 2:35 AM 644 views

In my custom module, When I removed field from both py/xml at a time , and then i am going to upgrade module at that time it gives this Architecture error.

I also used  -u My_module_name -d my_DB_name

But If i removed code from Xml and upgrade modules then after 

         I removed code from py and upgrade modules then it will work,

I also checked with my other develop's system.

When I test this case with other object it works fine. 

My code is below:

class res_users(osv.osv):
    _inherit = "res.users"

    _columns = {
        'analytic_account_id': fields.many2one('account.analytic.account', 'Analytic Department'),


<record model="ir.ui.view" id="view_user_base_extended_form">
            <field name="name">res.users.base.form</field>
            <field name="model">res.users</field>
            <field name="inherit_id" ref="base.view_users_form" />
            <field name="arch" type="xml">
                <field name="company_id" position="after">
                    <field name="analytic_account_id" groups="base_extended.group_analytic_department"/>

ITS Happened Only when we defind Security Group  In security.xml.

Did you upgrade the module in the web?

Nanie BE
on 10/23/14, 2:23 AM

It Happened once for me also... In Alpha version views [which is edited from browser] wont get replaced when you upgrade the module..

on 10/24/14, 9:14 AM

Yes Nanie BE. you can also try with this code in new module. & also define security group, i am sure you also get this type of error.

Piyush Suva
on 10/27/14, 1:27 AM

Atchuthan - Technical Consultant, Sodexis Inc

--Atchuthan - Technical Consultant, Sodexis Inc--
| 5 3 8
Puducherry, India
--Atchuthan - Technical Consultant, Sodexis Inc--
Passionate coder in Python/Odoo(formerly known as OpenERP).

Contact me via GMail: atchuthantu@gmail.com via Skype: atchuthan_skype
via Linkedin: http://in.linkedin.com/in/atchuthantu
Atchuthan - Technical Consultant, Sodexis Inc
On 10/27/14, 1:47 AM

When a XML record is removed, this does not mean that the form view is not available in DB.  So, always try to remove the exact form view from ir.ui.view table.

delete from ir_ui_view where id in (select id from ir_ui_view where name ilike '%res.users.base.form%')

no man, it should be removed. that's why we upgrade module. thing is that it happen only when you put new security group in security file and object is res.users, (like mention in question.) Otherwise its working fine.

Piyush Suva
on 10/27/14, 2:13 AM

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

3 follower(s)


Asked: 10/18/14, 2:35 AM
Seen: 644 times
Last updated: 3/16/15, 8:10 AM