[Spambayes] [ spambayes-Bugs-716684 ] Filtering marks message as unread

SourceForge.net noreply at sourceforge.net
Mon Apr 7 20:21:54 EDT 2003


Bugs item #716684, was opened at 2003-04-07 21:28
Message generated for change (Comment added) made by mhammond
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=498103&aid=716684&group_id=61702

Category: Outlook
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Mark Hammond (mhammond)
Assigned to: Mark Hammond (mhammond)
Summary: Filtering marks message as unread

Initial Comment:
Reported too many times :)  Exchange server users only.

As spambayes startsit starts processing missed
messages.  In the meantime, the user reads some
messages, thereby marking them as read.  As smapbayes
writes the spam field, these messages spring back to a
read status.

----------------------------------------------------------------------

>Comment By: Mark Hammond (mhammond)
Date: 2003-04-08 12:21

Message:
Logged In: YES 
user_id=14198

>From David Bolen:
"Moore, Paul" <Paul.Moore at atosorigin.com> writes:

> As far as I know, no-one has been able to track down the 
> problem to fix it yet.

I have, however, implemented a local workaround that's
working really well for me.  This was based on my prior
messages in:

   
http://mail.python.org/pipermail/spambayes/2003-March/004086.html
   
http://mail.python.org/pipermail/spambayes/2003-March/004088.html

Since I can't quantify what if any penalty it imposes in the
general
case by syncing changes back to the server an additional
time, and
since the problem may be limited to Exchange servers, I haven't
proposed it be made to the main source yet - although I
certainly
haven't noticed much of a penalty in my local testing.

But if anyone else wants to try a local change, it's fairly
trivial,
adding an additional call to msg.Save() in filter.py:

    *** filter.py   18 Mar 2003 03:09:03 -0000      1.20
    --- filter.py   7 Apr 2003 22:18:58 -0000
    ***************
    *** 27,39 ****
          try:
              # Save the score
              msg.SetField(mgr.config.field_score_name, prob)
              # and the ID of the folder we were in when scored.
              # (but only if we want to perform all actions)
              # Note we must do this, and the Save, before the
              # filter, else the save will fail.
              if all_actions:
                  msg.RememberMessageCurrentFolder()
    !         msg.Save()

              if all_actions and attr_prefix is not None:
                  folder_id = getattr(config, attr_prefix +
"_folder_id")
    --- 26,39 ----
          try:
              # Save the score
              msg.SetField(mgr.config.field_score_name, prob)
    +         msg.Save()
              # and the ID of the folder we were in when scored.
              # (but only if we want to perform all actions)
              # Note we must do this, and the Save, before the
              # filter, else the save will fail.
              if all_actions:
                  msg.RememberMessageCurrentFolder()
    !             msg.Save()

              if all_actions and attr_prefix is not None:
                  folder_id = getattr(config, attr_prefix +
"_folder_id")


After making this change, what went from virtually _every_
message staying unread, became the extreme rare case, such
that I'm no longer certain any remaining case may even be
spambayes related.


----------------------------------------------------------------------

Comment By: Martin Worger (worger)
Date: 2003-04-07 21:58

Message:
Logged In: YES 
user_id=751487

A bit of investigation (I am using Outlook 2002 & Exchange 
2000).

A new message arriving in my Inbox does not get analysed by 
SpamBayes until:
- You switch to another folder and back again.
- You read the message (then analysed, but remains 'unread')
- Another email arrives, when the first message is then rated 
(second one not rated though)
- Another email in Inbox is saved after editing
In other words, it seems some other action eventually triggers 
the analysis - not the arrival event itself.

An email that is read before it has been analysed by 
SpamBayes will always be 'unread' afterwards. This is 
independent of type (plain, rich text or HTML)

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=498103&aid=716684&group_id=61702



More information about the Spambayes mailing list