[5.0] Error when export an empty field

Bug #425430 reported by Christophe CHAUVET
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Fix Released
Undecided
Unassigned

Bug Description

Hi

When i try to export (gtk client), with an empty field, i have this traceback

I have made patch to correct this issue, see below

---------8<-------------------8<-------------
[2009-09-07 00:07:14,777] ERROR:web-services01]:
[2009-09-07 00:07:14,778] ERROR:web-services02]: Environment Information :
[2009-09-07 00:07:14,778] ERROR:web-services03]: System : Linux-2.6.28-15-generic-x86_64-with-Ubuntu-9.04-jaunty
[2009-09-07 00:07:14,778] ERROR:web-services04]: OS Name : posix
[2009-09-07 00:07:14,779] ERROR:web-services05]: Distributor ID: Ubuntu
[2009-09-07 00:07:14,779] ERROR:web-services06]: Description: Ubuntu 9.04
[2009-09-07 00:07:14,779] ERROR:web-services07]: Release: 9.04
[2009-09-07 00:07:14,779] ERROR:web-services08]: Codename: jaunty
[2009-09-07 00:07:14,779] ERROR:web-services09]: Operating System Release : 2.6.28-15-generic
[2009-09-07 00:07:14,779] ERROR:web-services10]: Operating System Version : #49-Ubuntu SMP Tue Aug 18 19:25:34 UTC 2009
[2009-09-07 00:07:14,780] ERROR:web-services11]: Operating System Architecture : 64bit
[2009-09-07 00:07:14,780] ERROR:web-services12]: Operating System Locale : fr_FR.UTF8
[2009-09-07 00:07:14,780] ERROR:web-services13]: Python Version : 2.6.2
[2009-09-07 00:07:14,780] ERROR:web-services14]: OpenERP-Server Version : 5.0.5-bzr
[2009-09-07 00:07:14,780] ERROR:web-services15]: Last revision No. & ID : 1856 <email address hidden>
[2009-09-07 00:07:14,780] ERROR:web-services16]: Traceback (most recent call last):
[2009-09-07 00:07:14,780] ERROR:web-services17]: File "/home/alnslang/bzrsyleam/openerp/5.0/officiel/server/bin/osv/osv.py", line 59, in wrapper
[2009-09-07 00:07:14,781] ERROR:web-services18]: return f(self, dbname, *args, **kwargs)
[2009-09-07 00:07:14,781] ERROR:web-services19]: File "/home/alnslang/bzrsyleam/openerp/5.0/officiel/server/bin/osv/osv.py", line 118, in execute
[2009-09-07 00:07:14,781] ERROR:web-services20]: res = pool.execute_cr(cr, uid, obj, method, *args, **kw)
[2009-09-07 00:07:14,782] ERROR:web-services21]: File "/home/alnslang/bzrsyleam/openerp/5.0/officiel/server/bin/osv/osv.py", line 110, in execute_cr
[2009-09-07 00:07:14,782] ERROR:web-services22]: return getattr(object, method)(cr, uid, *args, **kw)
[2009-09-07 00:07:14,782] ERROR:web-services23]: File "/home/alnslang/bzrsyleam/openerp/5.0/officiel/server/bin/osv/orm.py", line 541, in export_data
[2009-09-07 00:07:14,782] ERROR:web-services24]: datas += self.__export_row(cr, uid, row, fields_to_export, context)
[2009-09-07 00:07:14,782] ERROR:web-services25]: File "/home/alnslang/bzrsyleam/openerp/5.0/officiel/server/bin/osv/orm.py", line 500, in __export_row
[2009-09-07 00:07:14,782] ERROR:web-services26]: dt+=rr.name+','
[2009-09-07 00:07:14,783] ERROR:web-services27]: TypeError: unsupported operand type(s) for +: 'bool' and 'str'
---------8<-------------------8<-------------

Tags: 5.0 export

Related branches

Revision history for this message
Christophe CHAUVET (christophe-chauvet) wrote :
Changed in openobject-server:
status: New → Confirmed
Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Thank you for the post and patch Christophe chauvet,

This would have been faced while exporting O2M records with False values on 'rec_name' field, but no more no onwards.

Fixed by revision 1858 <email address hidden>.

Thank you.

Changed in openobject-server:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.