Subject: is this a bug in c-client or in server?

From: Vadim Zeitlin <[email-masked]>
Date: Sun, 10 Jun 2001 03:58:23 +0200 (Romance Daylight Time)

Hello,

 I'm having some trouble understanding why copying the messages to one IMAP
server doesn't work. I suspect it is a bug in the server but this seems so
incredible that I'm not sure... Here is the c-client debug log:

03:42:13: Saving 1 message(s) to 'Test Accounts/GroupWise6/INBOX'...
03:42:13:  * OK GroupWise IMAP4rev1 Server Ready
03:42:13: Mail log (Test Accounts/GroupWise6/INBOX):GroupWise IMAP4rev1 Server Ready, error level: 0
03:42:13:  00000000 CAPABILITY
03:42:14:  * CAPABILITY IMAP4rev1 STARTTLS
03:42:14:  00000000 OK CAPABILITY completed
03:42:14:  00000001 LOGIN mahogany *******
03:42:14:  00000001 OK LOGIN completed
03:42:14:  00000002 CAPABILITY
03:42:14:  * CAPABILITY IMAP4rev1 STARTTLS
03:42:14:  00000002 OK CAPABILITY completed
03:42:14:  00000003 SELECT INBOX
03:42:14:  * 0 EXISTS
03:42:15:  * OK [UIDVALIDITY 3]
03:42:15:  * FLAGS (\Answered \Flagged \Deleted \Draft \Seen)
03:42:15:  * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Draft \Seen \*)]
03:42:15:  00000003 OK [READ-WRITE] SELECT completed
03:42:15: Mailbox is empty, error level: 0
03:42:15:  00000004 APPEND INBOX (\SEEN) " 9-Jun-2001 22:44:39 +0100" {2524}
03:42:15:  + Ready
03:42:15:  00000004 OK APPEND completed
03:42:15:  00000005 NOOP
03:42:16:  * 0 EXISTS
03:42:16:  00000005 OK NOOP completed
03:42:16:  00000006 CHECK
03:42:16:  00000006 OK CHECK completed
03:42:16: CHECK completed, error level: 0
03:42:16: Saving 1 message(s) to 'Test Accounts/GroupWise6/INBOX'... done

I.e. APPEND results in an OK reply but there are no messages in the INBOX
after it! Obviously, this is a big problem, especially when the messages
are moved and not copied... The only solution I see is to check that the
number of messages has been indeed incremented after calling mail_append(),
but this seems rather ugly. Is there something I'm missing here, i.e. am I
doing something wrong or maybe there is another way to check that append
succeeded (I don't have any control over the server)?

 Thanks!
VZ

-- 
------------------------------------------------------------------
 For information about this mailing list, and its archives, see: 
 http://www.washington.edu/imap/c-client-list.html
------------------------------------------------------------------

---

From: Mark Crispin <[email-masked]>
Date: Sun, 10 Jun 2001 12:37:23 -0700 (PDT)

It is certainly not a c-client bug.

It may be a server bug.  The GroupWise server has had problems in the past.
However, it may be as simple a matter as the server not acquiring the new
message right away when you append to the currently-selected mailbox.  Did you
try closing the current IMAP session, then re-opening it to see if the message
got there after all?

If the message did eventually appear in the INBOX, then in the strictest sense
the server is complying with the IMAP protocol.  There is no requirement in
IMAP that the server MUST immediately reflect message delivery to a selected
mailbox; or, put another way, it is compliant for a server not to discover new
mail except at select time.

HOWEVER!!  In terms of "quality of implementation", a server which does not
immediately reflect message delivery to a selected mailbox can not be
considered to be of good quality.  Users have a reasonable expection that
their active IMAP sessions see new mail as it is delivered.

To summarize:
 . From the evidence you submitted, the GroupWise server either has a bug, or
   has a quality of implementation problem.  Either way, the vendor should be
   notified and asked for remedial action.
 . The evidence you submitted shows no problem in c-client.
 . Your application should not attempt to do any test (such as check if the
   number of messages has been implemented).  There is no reasonable test; and
   it is possible to have a "delayed effect" that would lead to false test
   results.

I understand your concern about moving messages; obviously it is a bad thing
to have messages be lost.  However, there isn't anything that you as a client
author can do about it; a defective server can destroy user data no matter
what steps a client takes.  The best strategy is to make sure that your client
is not defective, and that you have sufficient logging facilities so that if a
problem occurs, it can be traced to the faulty agent (client or server) so
that the fault can be repaired.

---

From: Eduardo Chappa <[email-masked]>
Date: Mon, 11 Jun 2001 14:41:01 -0700 (PDT)

*** Mark Crispin ([email-masked]) wrote on Jun 10, 2001:

:) HOWEVER!!  In terms of "quality of implementation", a server which does not
:) immediately reflect message delivery to a selected mailbox can not be
:) considered to be of good quality.  Users have a reasonable expection that
:) their active IMAP sessions see new mail as it is delivered.

Mark,

  I have noticed this problem with your server in the Math Department (we
are using the server distributed with version 4.33). Sometimes I have
copied messages to the INBOX folder with pine (modified and unmodified
source), and Pine has not noticed the new mail for quite some time (I mean
enough time that you consider it long). The message is in the INBOX, and
despite the fact that I press ^L, the "N" key at the bottom of the index
or the down arrow key also at the bottom of the index I do not see the new
mail in Pine. The new mail has not been noticed, even though I have the
new feature "check-mail-when-quitting" enabled in Pine. The next time I
open the inbox the message is marked as "N" (as opposed to "U" in
IMAPSTATUS). This is not a problem with the above mentioned feature,
somehow the "newmail" function is not noticing this new message.

  However, when I added back the pseudo message to my inbox I never
suffered that problem again. I believe this is a problem in the server.
What do you think? Do you need some debug logs?

  Thanks.

-- 
Eduardo
http://www.math.washington.edu/~chappa/pine/

---

From: "Jason Rem" <[email-masked]>
Date: Mon, 11 Jun 2001 14:56:48 -0700

Mark,

Do you know of a website or destination I can query to determine who uses
IMAP email in terms of overall numbers and specific institution/business
names. It seems that IT Managers have had problems delivering IMAP email to
Research In Motion (RIM) devices and our company has recently come up with a
solution to that problem. Looking to determine if others need help solving
this problem.

Thank you,

Jason Rem

-----Original Message-----
From: [email-masked]
[mailto:[email-masked]]On Behalf Of Eduardo Chappa
Sent: Monday, June 11, 2001 2:41 PM
To: [email-masked]
Subject: re: is this a bug in c-client or in server?

:) HOWEVER!!  In terms of "quality of implementation", a server which does
not
:) immediately reflect message delivery to a selected mailbox can not be
:) considered to be of good quality.  Users have a reasonable expection that
:) their active IMAP sessions see new mail as it is delivered.

Mark,

  Thanks.