[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to unregister message as spam/ham?
From: |
Adam Sjøgren |
Subject: |
Re: How to unregister message as spam/ham? |
Date: |
Sun, 06 Sep 2009 13:50:46 +0200 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) XEmacs/21.5-b29 (linux) |
On Sun, 06 Sep 2009 12:42:51 +0200, Adam wrote:
> Looking in the code, unregistering seems to be handled for bogofilter:
Ah, it is - but an article isn't unregistered if it is going from ham to
spam, or spam to ham, because, in spam.el's spam-resolve-registrations-routine
this happens:
;; eliminate duplicates
(dolist (article (copy-sequence ulist))
(when (memq article rlist)
(incf delcount)
(setq rlist (delq article rlist))
(setq ulist (delq article ulist))))
If you crank up gnus-verbose, your test will say something like:
"1 messages were saved the trouble of unregistering and then registering"
If you comment out the eliminate duplicates-part quoted above, I think
it will do the unregistering as you expect/want.
o o o
Oh, and I also said:
> Ah. When I set up crm114 it didn't have this functionality, I think, so
> I wasn't aware of it.
Looks like crm114 gained an '--unlearn' switch at some point.
I can't really figure out where the source code repository for crm114
lives, so exactly when is unclear to me (my guesses are either 20040407
og 16 Jan 2009:
http://crm114.git.sourceforge.net/git/gitweb.cgi?p=crm114/crm114;a=commit;h=31f68a7f24c300cb3c2cbb09b245f348265eed19
.)
But here is a patch that adds support for it to spam.el:
diff --git a/lisp/spam.el b/lisp/spam.el
index c315f2f..e2d34b6 100644
--- a/lisp/spam.el
+++ b/lisp/spam.el
@@ -659,12 +659,12 @@ order for SpamAssassin to recognize the new registered
spam."
:type 'string
:group 'spam-crm114)
-(defcustom spam-crm114-spam-strong-switch "--UNKNOWN"
+(defcustom spam-crm114-spam-strong-switch "--unlearn"
"The switch that CRM114 Mailfilter uses to unregister ham messages."
:type 'string
:group 'spam-crm114)
-(defcustom spam-crm114-ham-strong-switch "--UNKNOWN"
+(defcustom spam-crm114-ham-strong-switch "--unlearn"
"The switch that CRM114 Mailfilter uses to unregister spam messages."
:type 'string
:group 'spam-crm114)
@@ -1151,10 +1151,8 @@ backends)."
'spam-check-crm114
'spam-crm114-register-ham-routine
'spam-crm114-register-spam-routine
- ;; does CRM114 Mailfilter support
unregistration?
- nil
- nil)
-
+ 'spam-crm114-unregister-ham-routine
+ 'spam-crm114-unregister-spam-routine)
;;}}}
;;{{{ scoring and summary formatting
--
1.6.3.3
--
"I'm not a monster, well, technically I am" Adam Sjøgren
asjo@koldfront.dk
- How to unregister message as spam/ham?, Teemu Likonen, 2009/09/06
- Re: How to unregister message as spam/ham?, Adam Sjøgren, 2009/09/06
- Re: How to unregister message as spam/ham?, Adam Sjøgren, 2009/09/06
- Re: How to unregister message as spam/ham?, Teemu Likonen, 2009/09/06
- Re: How to unregister message as spam/ham?, Adam Sjøgren, 2009/09/06
- Re: How to unregister message as spam/ham?,
Adam Sjøgren <=
- Re: How to unregister message as spam/ham?, Teemu Likonen, 2009/09/06
- Re: How to unregister message as spam/ham?, Adam Sjøgren, 2009/09/06
- Re: How to unregister message as spam/ham?, Ted Zlatanov, 2009/09/09
- Re: How to unregister message as spam/ham?, Adam Sjøgren, 2009/09/09
- spam2.el (was: How to unregister message as spam/ham?), Ted Zlatanov, 2009/09/10
- Re: spam2.el, Adam Sjøgren, 2009/09/10
- Re: spam2.el (was: How to unregister message as spam/ham?), Adam Sjøgren, 2009/09/10
- Re: spam2.el (was: How to unregister message as spam/ham?), Ted Zlatanov, 2009/09/14
- Re: spam2.el, Teemu Likonen, 2009/09/10
- Re: spam2.el, Adam Sjøgren, 2009/09/10