org-msg icon indicating copy to clipboard operation
org-msg copied to clipboard

Email with Latex Equation in org-msg (mu4e) does not convert and send

Open TS-CUBED opened this issue 4 years ago • 3 comments

What did you expect to happen?

Using mu4e with org-msg, I include a LaTeX equation in the email body and expect it to be included as a png image. What actually happened?

When attempting to send the message (C-c C-c), the message is not sent if it includes a LaTeX eqyuation (tex:dvipng)

Error (message-send-hook): Error running hook "org-msg-prepare-to-send" because: (void-variable source)

or:

condition-case: Error in a Doom startup hook: message-send-hook, org-msg-prepare-to-send, (void-variable source)

Describe your attempts to resolve the issue

Email does get sent with

images attached, or created using babel source blocks (e.g. Python or Julia blocks)
other rich text formatting using org-mode (headers, tables, lists, etc.)

only LaTeX equations trigger the error above.

Using tex:dvisvgm works, and attaches the LaTeX equation, but email clients don't handle svg files well. Steps to reproduce

Open Emacs
Start Mu4E
"C" to compose message, enter recipient
In message body, enter equation: $\sin(\alpha)$
"C-c C-c"
error message:
Error (message-send-hook): Error running hook "org-msg-prepare-to-send" because: (void-variable source)

System Information

https://pastebin.com/tPcqXb2Y

TS-CUBED avatar Sep 01 '21 22:09 TS-CUBED

I'm using the option tex:imagemagick successfully. Can you try that?

danielfleischer avatar Sep 12 '21 07:09 danielfleischer

Thanks Daniel,

that seems to work.

Although I'd rather not use imagemagick, TBH.

There is a bug in imagemagick, and you have to explicitely allow the pdf translation (which has been disabled because of that bug), thus reducing the security on the system.

TS-CUBED avatar Sep 22 '21 11:09 TS-CUBED

FWIW I am also having this issue. Same exact behavior. Imagemagick works but I have a similar concern.

jsilve24 avatar Sep 30 '21 21:09 jsilve24