[Spambayes] Re: SpamBayes Outlook Plug-In
Mark Hammond
mhammond at skippinet.com.au
Tue Apr 8 13:10:26 EDT 2003
Would it be possible to try another change for me instead? Revert
filter.py, and in msgstore.py's Save method, find the line:
self.mapi_object.SaveChanges(mapi.KEEP_OPEN_READWRITE |
USE_DEFERRED_ERRORS)
And remove "USE_DEFERRED_ERRORS" from it. See if the behaviour changes. If
not, then try finding the definition of USE_DEFERRED_ERRORS, and change it
to 0, thereby preventing *any* code in this file passing that funky MAPI
flag.
I am kinda hoping this will cause me to be a MAPI_E_OBJECT_CHANGED error,
which would allow a more elegant solution to the problem.
I'm a little unsure why one of the Save calls is indented too.
BTW, I've opened
http://sourceforge.net/tracker/index.php?func=detail&aid=716684&group_id=617
02&atid=498103 to track this.
Thanks,
Mark.
> -----Original Message-----
> From: spambayes-bounces at python.org
> [mailto:spambayes-bounces at python.org]On Behalf Of David Bolen
> Sent: Tuesday, 8 April 2003 8:26 AM
> To: spambayes at python.org
> Subject: [Spambayes] Re: SpamBayes Outlook Plug-In
>
>
> "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.
>
> --
> -- David
> --
> /-----------------------------------------------------------------------\
> \ David Bolen \ E-mail: db3l at fitlinxx.com /
> | FitLinxx, Inc. \ Phone: (203) 708-5192 |
> / 860 Canal Street, Stamford, CT 06902 \ Fax: (203) 316-5150 \
> \-----------------------------------------------------------------------/
>
>
> _______________________________________________
> Spambayes mailing list
> Spambayes at python.org
> http://mail.python.org/mailman/listinfo/spambayes
>
More information about the Spambayes
mailing list