Skip to Content
Menú
This question has been flagged
3 Respostes
8350 Vistes

I am testing Odoo v8 on Ubuntu 14.04 and after some testing, I can no longer edit the company info. I get the following error:

Traceback (most recent call last): File "/opt/odoo/odoo-server/openerp/http.py", line 476, in _handle_exception return super(JsonRequest, self)._handle_exception(exception) File "/opt/odoo/odoo-server/openerp/http.py", line 495, in dispatch result = self._call_function(**self.params) File "/opt/odoo/odoo-server/openerp/http.py", line 311, in _call_function return checked_call(self.db, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/service/model.py", line 113, in wrapper return f(dbname, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/http.py", line 308, in checked_call return self.endpoint(*a, **kw) File "/opt/odoo/odoo-server/openerp/http.py", line 685, in __call__ return self.method(*args, **kw) File "/opt/odoo/odoo-server/openerp/http.py", line 360, in response_wrap response = f(*args, **kw) File "/opt/odoo/odoo-server/addons/web/controllers/main.py", line 983, in call_kw return self._call_kw(model, method, args, kwargs) File "/opt/odoo/odoo-server/addons/web/controllers/main.py", line 966, in _call_kw records = getattr(request.session.model(model), method)(*args, **kwargs) File "/opt/odoo/odoo-server/openerp/http.py", line 787, in proxy result = meth(cr, request.uid, *args, **kw) File "/opt/odoo/odoo-server/openerp/api.py", line 204, in wrapper return old_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 3106, in read result = BaseModel.read(records, fields, load=load) File "/opt/odoo/odoo-server/openerp/api.py", line 202, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/models.py", line 3095, in read values[name] = field.convert_to_read(record[name], use_name_get) File "/opt/odoo/odoo-server/openerp/fields.py", line 1324, in convert_to_read return value.sudo().name_get()[0] File "/opt/odoo/odoo-server/openerp/api.py", line 202, in wrapper return new_api(self, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/api.py", line 519, in new_api result = method(self._model, cr, uid, self.ids, *args, **kwargs) File "/opt/odoo/odoo-server/openerp/addons/base/res/res_partner.py", line 600, in name_get name = name.replace('\n\n','\n') AttributeError: 'bool' object has no attribute 'replace'

Does anybody have a clue?

Tnx.

Avatar
Descartar
Best Answer

Have you renamed your company outside of OpenERP, for example directly on the database?

Of did you perhaps delete the partner (in the res.partner table) that was automatically created with the company? 

Avatar
Descartar
Best Answer

Interesting. The error is because variable name is bool object. It should be string. Did you ever edit res_partner.py before line 600 in name_get method? If you never edit the file, it could be a bug.

Avatar
Descartar
Autor Best Answer

I have never edited the file, or the record. The problem started when I added an event (in event management). I could delete the event and continue, although adding another event would give the same error. After that I deinstalled the event management app. Perhaps that me have caused the problem with the company records?

Avatar
Descartar

Could very well be. If you have access to the database using Postgres, I would recommend querying the company (select id,name from res_company) and/or the partner (select id,name from res_partner order by id desc) to check if both are still in there and have their respective names.