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.


ImportError: No module named osv

John O'Toole
on 7/13/15, 8:58 PM 1,379 views

Hello Odoo Community!

Does this error message sound familiar to you?


It is displayed when any user tries to install an application or module, and it reads as follows:

Odoo Server Error
Traceback (most recent call last):
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 530, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 567, in dispatch
result = self._call_function(**self.params)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 303, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/service/model.py", line 113, in wrapper
return f(dbname, *args, **kwargs)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 300, in checked_call
return self.endpoint(*a, **kw)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 796, in __call__
return self.method(*args, **kw)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/http.py", line 396, in response_wrap
response = f(*args, **kw)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/web/controllers/main.py", line 940, in call_button
action = self._call_kw(model, method, args, {})
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/web/controllers/main.py", line 928, in _call_kw
return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/api.py", line 241, in wrapper
return old_api(self, *args, **kwargs)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/base/module/module.py", line 450, in button_immediate_install
return self._button_immediate_function(cr, uid, ids, self.button_install, context=context)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/api.py", line 241, in wrapper
return old_api(self, *args, **kwargs)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/base/module/module.py", line 498, in _button_immediate_function
registry = openerp.modules.registry.RegistryManager.new(cr.dbname, update_module=True)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/registry.py", line 368, in new
openerp.modules.load_modules(registry._db, force_demo, status, update_module)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/loading.py", line 355, in load_modules
loaded_modules, update_module)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/loading.py", line 255, in load_marked_modules
loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/loading.py", line 143, in load_module_graph
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/module.py", line 315, in load_openerp_module
__import__('openerp.addons.' + module_name)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/modules/module.py", line 80, in load_module
mod = imp.load_module('openerp.addons.' + module_part, f, path, descr)
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/base_contact/__init__.py", line 22, in <module>
import base_contact
File "/opt/bitnami/apps/odoo/lib/odoo-8.0_20150423-py2.7.egg/openerp/addons/base_contact/base_contact.py", line 22, in <module>
from osv import fields, osv
ImportError: No module named osv

Thanks in advanced!


Axel Mendoza

--Axel Mendoza--
| 6 7 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full time employee trying to understand what to do an how

Reach me at aekroft@gmail.com

Axel Mendoza
On 7/13/15, 11:10 PM

you need to change that import


from osv import fields, osv 


from openerp.osv import fields, osv 

Ermin Trevisan

--Ermin Trevisan--
| 6 3 7
Walchwil, Switzerland
--Ermin Trevisan--

Ermin Trevisan
On 7/14/15, 2:18 AM

John seems to have a bitnami installation. I believe that something went wrong with the installation, because there is a module osv.py in the standard installation. Maybe a missing or wrong path configuration. It should not be necessary to change code like that. Also, a newer version of Odoo is available on Bitnami, I would try to install the newer one.

That code works in v7, I still use it, but in new versions this are not posible, this one of the things that I do when migrating my modules from v7 to v9 alfa and I think that in v8 doesn't work that too

Axel Mendoza
on 7/14/15, 3:09 AM

Axel, I do not deny your analysis. I only state that no Bitnami Odoo installation would work when your code change would be necessary and the whole Bitnami Odoo community would well know about it. But as this is not the case, the true cause must be in the installation or configuration process.

Ermin Trevisan
on 7/14/15, 3:16 AM

Last year I have made several Odoo Bitnami installations myself and I never had an issue like that.

Ermin Trevisan
on 7/14/15, 3:20 AM

The thing is that base_contact(taken from the logs you post) is a very old module (deprecated and no longer used in new versions) so if your bitnami installation is configured for use it that is the root cause of your troubles

Axel Mendoza
on 7/17/15, 12:36 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

2 follower(s)


Asked: 7/13/15, 8:58 PM
Seen: 1379 times
Last updated: 7/14/15, 2:27 AM