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.


How to fix "ImportError: No module named openerp.osv "?

on 6/20/13, 4:15 AM 16,316 views

Hi I am using Win 7 with eclipse IDE along with Python . I have created a custom module for openerp 7. My module updated successfully and it is in the openerp module list . Now I am trying to add fields in my module , but when I try to declare fields I am facing an error ( " ImportError: No module named openerp.osv ") . How to overcome this issue ? Please help

Hopes for suggestion . Thanks

Lakay lakay
On 8/27/14, 4:28 AM

im also creating simple modules for openERP v 7.0 until i encountered this problem in Odoo v8.0 (former openERP), i solved this problem by changing the traditional syntax for import  from  from osv import fields,osv   to    from openerp.osv import osv, fields     and make sure in your __init__.py   to remove the extension ".py" , example   import student  not import student.py    .... this works for me, i hope this will also work for you.

Alec Mouti
On 5/12/14, 6:58 AM

How did you solve this problem? I have same problem. my openerp-server on eclipse but I get the error when I debug addons modules. I'm quite sure is eclipse configuration. googled all over but people assume once openerp-server start on eclipse then people will be able to debug modules. that is completely wrong. you get this ImportError: No module named openerp.osv that many tutorials do not address. I'm still to see a tutorial on eclipse debug that works without people raising this issue


Ghanshyam Prajapati

--Ghanshyam Prajapati--
| 4 4 8
Pune, India
--Ghanshyam Prajapati--
OpenERP Developer
Ghanshyam Prajapati
On 6/20/13, 4:20 AM

Hi Arsalan, Try,

from openerp.osv import fields, osv

class your_class_name(osv.Model):

Hope it work for you.

Thanks but it didnot work . Am I making any configuration mistake or should I use some other IDE for running my code. I am a bit worried about this issue. Please help

on 6/20/13, 6:40 AM
On 6/20/13, 6:03 AM

I think the correct import statement dependent on the revision of openerp v7. If you use an older revision , you could try "from osv import fields, osv" as stated in the technical memento of openerp v7.

I have tried " from osv import fields , osv" but still the same issue , Do me a favour , tell me about the configuration because may be it is some configuration issue

on 6/20/13, 6:53 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

1 follower(s)


Asked: 6/20/13, 4:15 AM
Seen: 16316 times
Last updated: 3/16/15, 8:10 AM