Re: emacs email appears empty

Subject: Re: emacs email appears empty

Date: Fri, 30 Sep 2011 17:31:59 -0700

To: Brian May, notmuch

Cc:

From: Jameson Graef Rollins


On Thu, 29 Sep 2011 11:21:21 +1000, Brian May <brian@microcomaustralia.com.au> wrote:
> Have seen several cases now where the message appears blank in the
> emacs interface. With nothing but the headers.
> 
> Pushing Shift+V shows the entire raw message. Nothing special, just a
> plain text email without any attachments.
> 
> MIME-Version: 1.0
> Content-Type: text/plain; charset=utf-8
> Content-Transfer-Encoding: 7bit
> 
> Any ideas?

I'll put money on these bad messages all originating from Apple mail
clients.  Apple mail clients have this horrible habit of producing
completely broken mime structure.  As an example, this is the mime
structure of a message I received with the X-Mailer header "Apple Mail
(2.1084)":

┬╴ multipart/alternative
├╴ text/plain
└┬╴ multipart/mixed
 ├╴ text/html
 ├╴ application/msword (attachment)
 ├╴ text/html
 ├╴ application/msword (attachment)
 ├╴ text/html
 ├╴ application/msword (attachment)
 └╴ text/html

Notice what's going on here: the body part is "multipart/alternative",
but the alternative to the "text/plain" part is "multipart/mixed", which
happens to include all of the attachments.  That's just plain wrong.

If your problem is because the content is not being displayed because
it's hidden in a multipart/alternative part for which there is a
content-less primary alternate, you might try setting
notmuch-show-all-multipart/alternative-parts in the your emacs
customization.  It's not elegant, but it might help.

hth.

jamie.
part-000.sig (application/pgp-signature)

Thread: