1
Change .eml file file type detection
Source: paperless-ngx/paperless-ngx#13546 · opened by @scibi
Description libmagic only reports message/rfc822 when the very first header of a file is From:, Received: or Return-Path:. A message saved from Gmail with "Download message" starts with MIME-Version:, and a message exported from Thunderbird starts with X-Mozilla-Status:, so for both libmagic returns text/plain (or text/html when the body is HTML). Because the consumer selects a parser purely from that detected MIME type, and MailDocumentParser advertises only message/rfc822, the mail parser is never a candidate for such files. The message is stored as a text document instead: no PDF archive via Gotenberg/Tika, no mail metadata, and the document content is the raw MIME source including base64 attachment blobs, which also ends up in the search index. Reprocessing does not help, because it runs the same detection again, and the behaviour is identical whether the file arrives through the UI, the API or the consume directory. Confirmed in the official 3.0.4 image with the two …
No pledges yet. Be the first to back this.
Comments
Similar requests
[Feature Request] Unification of Email processing
42 votes · 0 comments
[Feature Request] Add a new consumption scope in paperless mail
1 vote · 0 comments
[Feature Request] Allow editing PDF that are imported from mails/eml files
3 votes · 0 comments
[Feature Request] Preserve original file when pre-consume script modifies document (garbled PDF text detection)
4 votes · 0 comments
[Feature Request] Append printed E-mail and/or attach e-mail body to PDF attachments
8 votes · 0 comments
No comments yet.