Text emails have html markup in PR descriptions and html encoding of unicode

Issue #62 closed
Mads Kiilerich created an issue

https://bitbucket.org/conservancy/kallithea/pull-request/21/send-emails-in-plain-text-too/diff

This issue do that I disagree with the approach taken there. Instead, we should first create html, then create a "text rendered" version of the html, using something similar to w3m -dump, perhaps https://github.com/aaronsw/html2text .

IMO, this should be fixed before we can make next release.

Comments (10)

  1. Andrej Shadura

    I think it'd be better to go other way around: generate markdown or rest and turn it into HTML, and, possibly, also strip extra markup before sending it out as plain text.

  2. Mads Kiilerich reporter

    Hmm. Yes, something like rst all the way might work. Assuming we never get user data in other / incompatible / inconvertible formats. It should still be able to handle markup of URLs and hashes in the html we send.

    (FWIW: Internally, I have disabled rst markup of our review comments. Comments are just for quick comments, commit messages are "something else", and 'ascii wysiwyg' is more efficient as long as we have markup of URLs and hashes.)

    Anyway, the way it is now might work for those who read html mails without any txt conversion and thus prefer "I have to deal with some html" over "I have to deal with a lot of html". But I think it is a regression for those who prefer text but can read html if necessary.

  3. Sean Farley

    I agree with Andrew that rst would be the better route. I have used html2txt for the past year in my email client and it has basically never worked (I have since switched to the eww to view the html).

  4. Andrej Shadura

    A short-term solution is to make sure HTML stuff doesn't get into the text version of the mails. I will try to work on that over the weekend.

  5. Log in to comment