Opened 10 years ago

Closed 7 years ago

#3412 task closed wontfix (wontfix)

Include link to IMAP Server Tester in Twisted IMAP documentation

Reported by: Ilpo Nyyssönen Owned by:
Priority: normal Milestone:
Component: mail Keywords: documentation
Cc: Thijs Triemstra Branch:

Description (last modified by Glyph)

biny suggested:

Twisted IMAP4 server should be tested with IMAP Server Tester.

but Twisted doesn't contain a full IMAP server, so there's no way to do that. The documentation for the storage APIs should include a reference to the IMAP server tester so that when people do implement the storage APIs they have a reference for testing.

Attachments (1) (10.4 KB) - added by Ilpo Nyyssönen 10 years ago.
Simple in memory imap server

Download all attachments as: .zip

Change History (10)

comment:1 Changed 10 years ago by Jean-Paul Calderone

Cc: Thijs Triemstra added
Keywords: documentation added

There isn't an IMAP4 server in Twisted. There's just a protocol implementation. There's no way to run this without implementing the storage APIs first.

Maybe the IMAP4 documentation in Twisted could point to this tool so that people who implement the storage APIs can benefit from it, though.

comment:2 Changed 10 years ago by Glyph

Description: modified (diff)
Summary: Test twisted.mail.imap4 with IMAP Server TesterInclude link to IMAP Server Tester in Twisted IMAP documentation

I've updated the summary and description to indicate what would currently count as a resolution of this ticket.

comment:3 Changed 10 years ago by Glyph

Normally I suggest that Twisted should include trivial implementations of all the storage backend APIs it supports; it does this for POP3, it does it for cred, and as recently discussed it will do it for XMPP. Should we have a separate ticket for implementing some trivial IMAP backend, or for adding one to twisted.mail.maildir? I am asking, rather than filing the ticket, because I don't actually know if there is such a thing as a "trivial" IMAP backend.

comment:4 Changed 10 years ago by Jean-Paul Calderone

We could probably have a simple one, but it'd be really, really low on my list of priorities. I can't see it really being of any practical use, though it might serve as a good example of how to write a storage backend.

Changed 10 years ago by Ilpo Nyyssönen

Attachment: added

Simple in memory imap server

comment:5 Changed 10 years ago by Ilpo Nyyssönen

OK, I wrote this simple in memory imap server for this.


I don't fully understand how IMailboxListener should be used and so those listeners are not notified.

Expunge needs fixing, I think.

Change RETURN_DEFERREDS to True make it a bit more realistic.

comment:6 Changed 10 years ago by Jean-Paul Calderone

Ummm. Okay... I'm not really sure what to do with this code. If it is going to be included in Twisted, then it needs docstrings and unit tests.

comment:7 Changed 9 years ago by Magneto

I think the problem of putting in an imapserver test is that it would be used by many as an example. This example is good but it has many shortcoming. For example: 1- Seen, Unseen flag, should be detected to reverse one and the other. 2- The mode == 0 in store flag is wrong, its not just discard, it should be "replace". Any many more which i discovered while trying to make it work, apart from Twisted itself having bugs in the (submitted as ticket).

Maybe Twisted can use the example in the Twisted Networking Essentials, there is an example of twisted imap server for maildir , that could be tweaked to be a more useful test unit and example. The community would love it.

comment:8 Changed 7 years ago by Thijs Triemstra

Resolution: wontfix
Status: newclosed

Closing (please reopen with other suggestions instead).

comment:9 Changed 7 years ago by <automation>

Owner: Jean-Paul Calderone deleted
Note: See TracTickets for help on using tickets.