FA-76587 / Email MIME structure / Member archive
Assemble the structure of a forwarded message: attach mode no duplicates · case 02
Forwarding as an attachment also copies the original attachments beside the attached message, duplicating them.
Case contract
original {subject, body_type ("text" or "alternative"), attachments [names], inline [image names]}. Subjects get a "Fwd: " prefix unless they already start with "fwd:" (case-insensitive). mode "attach" produces mixed(text,message/rfc822): the original travels whole, attachments included. mode "inline" copies the body: alternative(text,html), with related(html, images...) when the original has inline images (kept only when html exists), or text; original attachments follow in their original order inside mixed(...).
Why this case matters
Forwarding rebuilds a MIME tree; errors duplicate attachments, lose inline images or stack Fwd: prefixes.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| attach mode keeps parts inside | {"structure": "mixed(text,message/rfc822,a2.pdf)", "subject": "Fwd: s"} | {"structure": "mixed(text,message/rfc822)", "subject": "Fwd: s"} | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗