Odoo Help


Customer import - mystery error?

Jeff Beidler
on 11/14/14, 11:45 AM 1,753 views

I'm attempting to import customer companies.  When I try to validate my .csv file, I get a blank pink message area.  (Error messages aren't very helpful if they contain no content!)  If I tail the openerp log file, I see the following:

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 500, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 517, in dispatch
    result = self._call_function(**self.params)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 283, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/service/model.py", line 113, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 280, in checked_call
    return self.endpoint(*a, **kw)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 733, in __call__
    return self.method(*args, **kw)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/http.py", line 376, in response_wrap
    response = f(*args, **kw)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/web/controllers/main.py", line 948, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/web/controllers/main.py", line 940, in _call_kw
    return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/api.py", line 237, in wrapper
    return old_api(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/base_import/models.py", line 327, in do
    cr, uid, import_fields, data, context=context)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/api.py", line 237, in wrapper
    return old_api(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/models.py", line 1090, in load
    context=context, log=messages.append):
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/models.py", line 1263, in _convert_records
    converted = convert(record, lambda field, err:\
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/base/ir/ir_fields.py", line 68, in fn
    converted[field], ws = converters[field](value)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/api.py", line 235, in wrapper
    return new_api(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/base/ir/ir_fields.py", line 364, in _str_to_many2one
    id, _, w2 = self.db_id_for(model, field, subfield, reference)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/api.py", line 235, in wrapper
    return new_api(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openerp-8.0_83bd9ee-py2.7.egg/openerp/addons/base/ir/ir_fields.py", line 316, in db_id_for
    ids = RelatedModel.name_search(name=value, operator='=')
TypeError: location_name_search() takes at least 3 arguments (3 given)

Any idea what Odoo is complaining about?

By selectively removing columns from my import file, I have found that it seems to be gagging on the "State" field. Not sure why this is, though. My test record contains "MN" for the "State" field, which is a valid record in res.country.state.

Jeff Beidler
on 11/14/14, 12:31 PM
Jeff Beidler
On 11/14/14, 1:55 PM

I think this is a bug.  I created an issue here:  https://github.com/odoo/odoo/issues/3659

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

1 follower(s)


Asked: 11/14/14, 11:45 AM
Seen: 1753 times
Last updated: 3/16/15, 8:10 AM