Odoo Help


Upgrade module in Windows: desperately need an answer!

Jean-Jacques Caillée
on 10/15/14, 1:51 PM 3,318 views

I am developping a new module in Odoo for one of my customer. I am using Windows and intend to port eventually that module on a Windows server.

In the development process, I have to frequently rewritre or add python code to my module.Whenever I do so, in order to upgrade my module, I have to: uninstall my module, delete it, erase it from the addons directory, stop and start the Odoo service, copy back my module in the addons directory, have Odoo upgrade its modules list, reinstall it. Every time I do so, I loose my Odoo objects (and the corresponding tables in the database) and the data. If I do not follow that path, I get unrecoverable errors whenever I try to "upgrade" the module through the Odoo button and have to do those steps anyways to recover my Odoo installation.

Not only is that time consuming, but it is also unthinkable in an eventual real installation. There must surely be another way.

Could someone help me?

Thanks Michael for the reference. I am already using Eclipse. I will try to configure it exactly like it is suggested in the guide.

Jean-Jacques Caillée
on 10/16/14, 11:58 AM

what unrecoverable errors occur?

Ben Bernard
on 10/16/14, 1:06 PM

Traceback (most recent call last): File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 499, in _handle_exception File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 516, in dispatch File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 282, in _call_function File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\service\model.py", line 113, in wrapper File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 279, in checked_call File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 732, in __call__ File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 375, in response_wrap File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\openerp\addons\web\controllers\main.py", line 1244, in load File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\http.py", line 834, in proxy File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\api.py", line 237, in wrapper File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\openerp\addons\base\ir\ir_actions.py", line 321, in read File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\api.py", line 237, in wrapper File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\models.py", line 3095, in read File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\api.py", line 235, in wrapper File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\models.py", line 3127, in read File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\api.py", line 235, in wrapper File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\models.py", line 3289, in _read_from_database File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\osv\fields.py", line 1308, in get File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\openerp\addons\base\ir\ir_actions.py", line 260, in _search_view File "C:\Program Files (x86)\Odoo 8.0-20140918-103809\server\.\openerp\modules\registry.py", line 100, in __getitem__ KeyError: u'sprim.lien'

Jean-Jacques Caillée
on 10/16/14, 1:52 PM

Sorry, no idea. Paste to pastebin, maybe?

Ben Bernard
on 10/16/14, 10:47 PM
Michael Watchorn
On 10/16/14, 10:48 AM

Have you been doing your development work in Eclipse (with the PyDev pluggin)? 
Here is a complete guide to Odoo development under Windows: https://www.odoo.com/forum/help-1/question/how-to-debug-odoo-in-eclipse-under-winows-36105

I am not an expert on the upgrade process so all I can do is speculate that Update is primarily an additive process. You should be able to modify the contents of a function, XML file etc, but can't go as far as to remove table fields, classes, or functions as part of an update.

Abdullah Sofan
On 12/22/14, 5:53 AM

Did you find a better way to upgrade in windows?

Hamid Darabi
On 10/16/14, 12:13 PM

How do you stop and start your odoo service? I believe you don't need to reinstall everything, just restart odoo and upgrade your module. I use Notepad++ and copy(replace) my files to addon folder in server then I restart the server using C:\Program Files (x86)\Odoo 8.0-20140918-103809\service\start.bat and upgrade my module using upgrade button (not delete and install again) and it works just fine.

Hi. I was starting and stopping Odoo service through services.msc. I guess I was wrong. I will try it your way...

Jean-Jacques Caillée
on 10/16/14, 1:37 PM

I have stopped and started the Odoo service your way. Still get a lot of errors

Jean-Jacques Caillée
on 10/16/14, 1:49 PM



| 5 3 6
Jakarta, Indonesia
On 12/22/14, 6:48 AM

Did you by any chance create a record in your old module and then remove it in the new module without any delete directive?

About This Community

This platform 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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

2 follower(s)


Asked: 10/15/14, 1:51 PM
Seen: 3318 times
Last updated: 3/16/15, 8:10 AM