Closed chrismacklin closed 5 years ago
Yes please, I'll gladly accept any patch that truncates the outgoing email subject. That should probably happen here: https://github.com/TurboGears/backlash/blob/master/backlash/tracing/reporters/mail.py#L110
I don't have a reproduction of this error to contribute and I'm about to leave the job that is now using this library, so the chances of me fixing this are low. I'm closing this issue.
For exceptions whose message is quite long, I end up with emails with no subject at all instead of a truncated subject body. Happy to submit a patch to fix this behavior. Looks like this library already replaces newlines with spaces, but RFC2822 section 2.1.1 suggests a practical hard limit at 998 characters. If you agree with this implementation, I will submit a patch that truncates all email subjects to this limit, potentially adding a trailing ellipsis or other indicator that the subject has been truncated.