openerp-community-reviewer team mailing list archive
-
openerp-community-reviewer team
-
Mailing list archive
-
Message #07702
[Bug 1342360] [NEW] [6.1] Fetchmail + file storage + duplicate attachment = uniqueness constraint violation
Public bug reported:
On a system with document storage enabled, fetchmail will try to create
a mail with attachment_ids set to [(6, 0, [1234, 1234])] if an email
contains the same document twice. This leads to the following error:
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 134, in message_new
self.message_append_dict(cr, uid, [res_id], msg_dict, context=context)
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 305, in message_append_dict
context = context)
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 269, in message_append
mail_message.create(cr, uid, data, context=context)
File "/home/openerp/openobject-addons/fetchmail/fetchmail.py", line 250, in create
res = super(mail_message,self).create(cr, uid, values, context=context)
File "/home/therp/bzr/openobject-server/openerp/osv/orm.py", line 4235, in create
result += self._columns[field].set(cr, self, id_new, field, vals[field], user, rel_context) or []
File "/home/therp/bzr/openobject-server/openerp/osv/fields.py", line 784, in set
cr.execute('insert into '+rel+' ('+id1+','+id2+') values (%s, %s)', (id, act_nbr))
File "/home/therp/bzr/openobject-server/openerp/sql_db.py", line 152, in wrapper
return f(self, *args, **kwargs)
File "/home/therp/bzr/openobject-server/openerp/sql_db.py", line 212, in execute
res = self._obj.execute(query, params)
IntegrityError: duplicate key value violates unique constraint "message_attachment_rel_message_id_key"
** Affects: ocb-addons
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of OpenERP
Community Backports, which is subscribed to OpenERP Community Backports
(Addons).
https://bugs.launchpad.net/bugs/1342360
Title:
[6.1] Fetchmail + file storage + duplicate attachment = uniqueness
constraint violation
Status in OpenERP Community Backports (Addons):
New
Bug description:
On a system with document storage enabled, fetchmail will try to
create a mail with attachment_ids set to [(6, 0, [1234, 1234])] if an
email contains the same document twice. This leads to the following
error:
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 134, in message_new
self.message_append_dict(cr, uid, [res_id], msg_dict, context=context)
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 305, in message_append_dict
context = context)
File "/home/openerp/openobject-addons/mail/mail_thread.py", line 269, in message_append
mail_message.create(cr, uid, data, context=context)
File "/home/openerp/openobject-addons/fetchmail/fetchmail.py", line 250, in create
res = super(mail_message,self).create(cr, uid, values, context=context)
File "/home/therp/bzr/openobject-server/openerp/osv/orm.py", line 4235, in create
result += self._columns[field].set(cr, self, id_new, field, vals[field], user, rel_context) or []
File "/home/therp/bzr/openobject-server/openerp/osv/fields.py", line 784, in set
cr.execute('insert into '+rel+' ('+id1+','+id2+') values (%s, %s)', (id, act_nbr))
File "/home/therp/bzr/openobject-server/openerp/sql_db.py", line 152, in wrapper
return f(self, *args, **kwargs)
File "/home/therp/bzr/openobject-server/openerp/sql_db.py", line 212, in execute
res = self._obj.execute(query, params)
IntegrityError: duplicate key value violates unique constraint "message_attachment_rel_message_id_key"
To manage notifications about this bug go to:
https://bugs.launchpad.net/ocb-addons/+bug/1342360/+subscriptions
Follow ups
References