Closed Bug 310847 Opened 19 years ago Closed 17 years ago

messages marked read immediately if selected while downloading (delay ignored)

Categories

(Thunderbird :: Mail Window Front End, defect)

x86
Windows 2000
defect
Not set
minor

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 316491

People

(Reporter: itismike, Assigned: mscott)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7
Build Identifier: http://download.mozilla.org/?product=thunderbird-1.5b1&os=win&lang=en-US

I noticed that the messages are getting marked as read just by clicking them,
and is seems to happen during the send/recieve process.

Reproducible: Always

Steps to Reproduce:
1. click Get Mail
2. before it finishes (you have to have lots of mail to recieve), select an
unread message [from any folder] for preview
3. the message I click will be immediatly marked as read

Actual Results:  
the message I click will be immediatly marked as read

Expected Results:  
the same rules for marking messages read that were set in Options-> Advanced-->
General [mine is set to mark as read after displaying for 99999 seconds] should
be obeyed regardless of what state Thunderbird is in
Summary: messages marked read IF selected WHILE send recieve is working → messages marked read immediately if selected while downloading (delay ignored)
I can confirm that TB unexpectedly marks a message as Read using Michael's
example.  I reproduced this by sending myself a large attachment (to give myself
time to perform the test).  While the message with the large attachment was
downloading, I clicked on a different Unread message (in a different mailbox)
and its status changed to Read.  I've set TB to wait 2147483 seconds before
marking a message as Read but TB seemed to ignore this value, as Michael wrote.

I don't think that the problem is limited to Michael's example.  Although I've
only been using TB for about a month, I believe that I've seen something similar
happen several times already.  In my case, after I've already selected and have
been in the process of reading an unrelated Unread message in the preview pane,
its status suddenly changes from Unread to Read when a timed mail check occurs.

I'm using TB 1.5 beta 1 (the only version that I've ever installed on my computer).

I think that the severity of this bug would better be "Normal" than "Minor".  I
depend on the ability to keep messages marked as Unread "forever" until I
manually mark them as Read.  FYI, unlike just flagging a message for follow-up,
keeping a message marked as Unread allows me to see at a glance which mailboxes
contain important messages because of the Unread counts in parentheses after the
mailbox names.  Performing searches for flagged messages does not provide the
same kind of visual feedback that I can get by looking at the folder/mailbox
tree on the left and the Unread counts in parentheses.  That is why I use this
method for tracking messages.

I'm happy with the workaround that suggests setting the "mark-as-read timeout
value" to a huge number, but only if I can depend on the behavior.  Otherwise it
will be too easy for me to fail to respond to a message if I don't happen to
notice at the time that TB has unexpectedly marked it as Read.
I've found an even easier way to reproduce the problem.

1) Set the "wait for N seconds before marking as read" to a big value and enable
the preview pane.
2) Click on Read message X.
3) Mark message X as Unread.
4) Click on unrelated message Y.
5) Click again on message X.
6) Click the Get Mail toolbar button.

Message X changes from Unread to Read.
For completeness, I just want to add a couple of more notes:

1) TB marks the message as Read when I set the timeout delay to 2,147,483 seconds (without commas) (which is about (2^31)/1000 and about 24 days) but not when I set it to 2,000,000 or even 3,000,000.  I also could not reproduce Michael's report with his timeout setting of 99,999.

2) I'm using POP3 and I always leave all mail on the server.

Regarding (1), I did a naive examination of the Mozilla code and it appears that the JavaScript SetTimeout function might add the amount of time that TB has been running to this user-specified value to obtain the final time value that represents the point in time when TB will mark the message as Read.

Because of the sum of these two values, it seems possible that this behavior could not only affect people who specify a timeout value that's about (2^31)/1000, but also people who leave TB running for weeks at a time (even if their timeout value is say five seconds).

The odd thing is that the timeout behavior works fine unless a mail check occurs, even if there's no new mail to download.  I tried to find the cause deep inside the Mozilla code base but I must admit my ignorance and my head was spinning after a few hours of searching for an explanation.

If there is no easy fix to the existing code, then I'm still in favor of having an option -- hidden or part of the UI -- that allows us to completely disable TB's automatic marking of messages as Read under all conditions.
I confirm.

It's the same behavior when opening a non-read mail from the result of a search in the search window. The delay set in the parameters is ignored and the mail is marked as read immediatly.

I use Thunderbird 1.5 but it was the same with the previous version.
I haven't discerned an exact pattern, but this is driving me crazy. I've tried various workarounds -- unsetting the option and then resetting it. Nothing has really helped. The strange thing is that it fixed itself and then broke itself again. Now, about half the time I start TB, the problem occurs and about half the time I start TB it doesn't. I can't tell what's making the difference. This is TB 1.5 on WinXP Pro SP2. I upgraded from the latest 1.0.x version.
(In reply to comment #3)
> For completeness, I just want to add a couple of more notes:
> ...
> If there is no easy fix to the existing code, then I'm still in favor of having
> an option -- hidden or part of the UI -- that allows us to completely disable
> TB's automatic marking of messages as Read under all conditions.

I am very strongly in favour of having this option. In fact, in the existing settings dialogue, the tick box next to 'Wait x seconds before marking a message as read' is entirely redundant, since ticking it but entering a value of 0 for x is the same as not having ticked it at all. Far better, in my opinion, would be to only automatically mark mail as read if the box is ticked. The same default behaviour can exist by setting the default value of x to zero. If the box is unticked, it would be nice if Thunderbird never automatically marked messages as read.
QA Contact: front-end
reported problem should be gone in v2.0
Status: UNCONFIRMED → RESOLVED
Closed: 17 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.