Open
Description
Optional extensions introduce a lot of ambiguity and undefined behaviour to the Blossom specs. I've seen this sentiment echoed by various people across different discussions.
So, I'm opening this issue to discuss: Should file extensions really be optional? And if so, why?
A few references:
- BUD-02: Should the URL in the blob descriptor contain the extension? #25 (comment)
- blossom: implement BUD-05 without optimizations fiatjaf/khatru#45 (comment)
- blossom: implement BUD-05 without optimizations fiatjaf/khatru#45 (comment)
Anthony's unsolicited, likely uninformed opinion: I would make extensions mandatory. I would also make server-side Content-Type
detection mandatory (possibly falling back to application/octet-stream
). And I would 100% remove this responsibility from clients.
This would simplify things and remove ambiguity in cases like:
- A Blossom server forwarding
GET /{SHA256}
to other blob stores, CDNs, etc. - Users uploading media with one extension (or none) and requesting the blob with another.
- Defining the
type
in the blob descriptor (i.e., making it mandatory) - Mirroring between servers, where the original server's content type detection becomes the single source of truth.
Possible counterexamples:
- Encrypted attachments (e.g., for GiftWrapped DMs), where users don’t want to reveal anything about the nature of the file.
Metadata
Metadata
Assignees
Labels
No labels