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.


Probelm with Module upgrade

on 5/18/14, 9:37 AM 741 views

I have custom module abc , in my abc.py i have inherited res.company and hr.employee to add more fields to it. Now sometimes it happends when i try to upgrade my abc module, it gives errors like the following. The following errors shows something wrongs with the res_company. When i removed inherited code of res_company. then gives on hr_employee, when i remove all the inherited code in my module. it gives errors on res_users.

Now i have removed all the code of res_company, and hr_employee, but it now gives error on res_users. what is the problem with modules.


Client Traceback (most recent call last): File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/http.py", line 204, in dispatch response["result"] = method(self, **self.params) File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/controllers/main.py", line 1132, in call_button action = self._call_kw(req, model, method, args, {}) File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/controllers/main.py", line 1120, in _call_kw return getattr(req.session.model(model), method)(*args, **kwargs) File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/session.py", line 42, in proxy result = self.proxy.execute_kw(self.session._db, self.session._uid, self.session._password, self.model, method, args, kw) File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/session.py", line 30, in proxy_method result = self.session.send(self.service_name, method, *args) File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/session.py", line 103, in send raise xmlrpclib.Fault(openerp.tools.ustr(e), formatted_info) Server Traceback (most recent call last): File "/home/inovtec/OpenERP/openerp-7.0/openerp/addons/web/session.py", line 89, in send return openerp.netsvc.dispatch_rpc(service_name, method, args) File "/home/inovtec/OpenERP/openerp-7.0/openerp/netsvc.py", line 292, in dispatch_rpc result = ExportService.getService(service_name).dispatch(method, params) File "/home/inovtec/OpenERP/openerp-7.0/openerp/service/web_services.py", line 622, in dispatch security.check(db,uid,passwd) File "/home/inovtec/OpenERP/openerp-7.0/openerp/service/security.py", line 40, in check pool = pooler.get_pool(db) File "/home/inovtec/OpenERP/openerp-7.0/openerp/pooler.py", line 49, in get_pool return get_db_and_pool(db_name, force_demo, status, update_module)[1] File "/home/inovtec/OpenERP/openerp-7.0/openerp/pooler.py", line 33, in get_db_and_pool registry = RegistryManager.get(db_name, force_demo, status, update_module) File "/home/inovtec/OpenERP/openerp-7.0/openerp/modules/registry.py", line 192, in get update_module) File "/home/inovtec/OpenERP/openerp-7.0/openerp/modules/registry.py", line 218, in new openerp.modules.load_modules(registry.db, force_demo, status, update_module) File "/home/inovtec/OpenERP/openerp-7.0/openerp/modules/loading.py", line 350, in load_modules force, status, report, loaded_modules, update_module) File "/home/inovtec/OpenERP/openerp-7.0/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 "/home/inovtec/OpenERP/openerp-7.0/openerp/modules/loading.py", line 165, in load_module_graph init_module_models(cr, package.name, models) File "/home/inovtec/OpenERP/openerp-7.0/openerp/modules/module.py", line 381, in init_module_models obj._auto_end(cr, {'module': module_name}) File "/home/inovtec/OpenERP/openerp-7.0/openerp/osv/orm.py", line 3232, in _auto_end cr.execute('ALTER TABLE "%s" ADD FOREIGN KEY ("%s") REFERENCES "%s" ON DELETE %s' % (t, k, r, d)) File "/home/inovtec/OpenERP/openerp-7.0/openerp/sql_db.py", line 161, in wrapper return f(self, *args, **kwargs) File "/home/inovtec/OpenERP/openerp-7.0/openerp/sql_db.py", line 226, in execute res = self._obj.execute(query, params) ProgrammingError: there is no primary key for referenced table "res_users"


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

1 follower(s)


Asked: 5/18/14, 9:37 AM
Seen: 741 times
Last updated: 3/16/15, 8:10 AM