Hacker News new | ask | show | jobs
by hnlmorg 543 days ago
I’m not exactly the biggest fan of JSON either but given the clusterfuck of established email technologies, moaning about JSON is a little hypocritical.

https://en.m.wikipedia.org/wiki/The_pot_calling_the_kettle_b...

1 comments

It's more: we have two clusterfucks now thus might as well use the one we know best.

At least no one tried to use YAML on the wire, so far anyway.

And that one is JMAP. IMAP is such a huge clusterfuck it is almost impossible to beat it.
IMAP is simple and elegant and not a "clusterfuck" at all.

(Source: implemented both serverside and clientside IMAP.)

IMAP is basically a database query language and as such it works as it should.

IMAP is both excellent and, annoyingly inconsistent so it's much more of a pain to develop reliable parsers for. I'm pretty happy to use IMAP generally, but I'm also... MODSEQ is wrapped with a () in some places, not but STATUS HIGHESTMODSEQ:

  . SELECT INBOX.Archive
  * 1239 EXISTS
  * 0 RECENT
  * FLAGS (\Answered \Flagged \Draft \Deleted \Seen $X-ME-Annot-2 $HasAttachment $IsNotification $IsMailingList $NotJunk $CanUnsubscribe)
  * OK [PERMANENTFLAGS (\Answered \Flagged \Draft \Deleted \Seen $X-ME-Annot-2 $HasAttachment $IsNotification $IsMailingList $NotJunk $CanUnsubscribe \*)] Ok
  * OK [UNSEEN 1221] Ok
  * OK [UIDVALIDITY 1108730350] Ok
  * OK [UIDNEXT 2231] Ok
  * OK [HIGHESTMODSEQ 40306873] Ok
  * OK [MAILBOXID (210306ee-5833-456b-bede-6d04757128b3)] Ok
  * OK [URLMECH INTERNAL] Ok
  * OK [ANNOTATIONS 65536] Ok
  . OK [READ-WRITE] Completed
  . FETCH 1 MODSEQ
  * OK [HIGHESTMODSEQ 40306873] CONDSTORE enabled by FETCH MODSEQ
  * 1 FETCH (MODSEQ (39570709))
  . OK Completed (0.000 sec)
And... the * operator ranges.

  . FETCH 2231:* (UID MODSEQ)
  * 1239 FETCH (UID 2230 MODSEQ (40306872))
  . OK Completed (0.001 sec)
Source: have also implemented both client and server side IMAP, and reviewed RFC9051 very closely.
So it is just coincidence that there are zero good IMAP clients out there? I have tried a lot of clients and nobody has managed an implementstion which is works well in practice.

And it is a pretty bad query language compared to something like SQL.

> So it is just coincidence that there are zero good IMAP clients out there?

Yes. Regardless of the email protocol, third-party clients will always be horrible as long as corporations view email as their enterprise moat.