← Back to team overview

credativ team mailing list archive

[Bug 909913] Re: [Extra-addons]smtpclient attachment mimetype hardcoded

 

Hello Martin,

Sorry for the wrong name.

Thank you!

-- 
You received this bug notification because you are a member of OpenERP
Framework Experts, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/909913

Title:
  [Extra-addons]smtpclient attachment mimetype hardcoded

Status in OpenERP Addons (modules):
  Won't Fix

Bug description:
  OpenERP 6.0.3 on Ubuntu 10.04
  I am using smtpclient to send emails  with attached pdf reports generated by jasper_reports. The plan is to automatically send these reports by use of the scheduler. I successfully receive the emails with attached report but I cannot open the pdf in Thunderbird because the mimetype is set to application/octet-stream. This is hardcoded in smtpclient.
  The octet-stream opening problem is a well-known and long-standing 'feature' of Thunderbird, I don't know if other MUAs suffer from it too but ultimately the fault lies with the generating program as (I believe) the email RFCs require the mimetype to properly describe the attachment.
  At present you just pass a list of filenames as the attachment parameter to send_email(). I think it should be changed to allow a list of dicts something like this: [{'filename': '/tmp/file', 'maintype':'application', 'subtype': 'pdf'}, {...}] with application/octet-stream as the fallback.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/909913/+subscriptions


References