Gnus development mailing list
 help / color / mirror / Atom feed
* spam.el + sa-learn
@ 2011-01-17 19:50 Tom Rauchenwald
  2011-01-19 21:32 ` Ted Zlatanov
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Rauchenwald @ 2011-01-17 19:50 UTC (permalink / raw)
  To: ding

[-- Attachment #1: Type: text/plain, Size: 633 bytes --]

Hi,

i recently noticed that my spamassassin bayes database didn't get
updated properly. sa-learn didn't pick up messages I fed it (via the
spam exit processors).

The following patch fixes it for me, but I'm not sure if it is the right
thing to do. For me it looks like sa-learn doesn't accept "From " alone
as message seperator anymore, so i added "nobody" and the current time
string. I'm on Debian Sid FWIW (SpamAssassin version 3.3.1).

Could someone more knowing about the issue comment on this?

Thanks,
-tom

-- 
You should never underestimate the predictability of stupidity. 
                -- Bullet Tooth Tony in Snatch

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: patch-spam.diff --]
[-- Type: text/x-diff, Size: 798 bytes --]

diff --git a/lisp/spam.el b/lisp/spam.el
index 194668e..cf729e3 100644
--- a/lisp/spam.el
+++ b/lisp/spam.el
@@ -2726,9 +2726,7 @@ With a non-nil REMOVE, remove the ADDRESSES."
               (with-current-buffer summary-buffer-name
                 (setq article-string (spam-get-article-as-string article)))
               (when (stringp article-string)
-                (insert "From \n") ; mbox separator (sa-learn only checks the
-                                   ; first five chars, so we can get away with
-                                   ; a bogus line))
+                (insert (concat "From nobody " (current-time-string) "\n")) ; mbox separator
                 (insert article-string)
                 (insert "\n"))))
           ;; call sa-learn on all messages at the same time

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: spam.el + sa-learn
  2011-01-17 19:50 spam.el + sa-learn Tom Rauchenwald
@ 2011-01-19 21:32 ` Ted Zlatanov
  2011-01-22  9:59   ` Tom Rauchenwald
  0 siblings, 1 reply; 3+ messages in thread
From: Ted Zlatanov @ 2011-01-19 21:32 UTC (permalink / raw)
  To: ding

On Mon, 17 Jan 2011 20:50:57 +0100 Tom Rauchenwald <sehnsucht.nach.unendlichkeit@quantentunnel.de> wrote: 

TR> i recently noticed that my spamassassin bayes database didn't get
TR> updated properly. sa-learn didn't pick up messages I fed it (via the
TR> spam exit processors).

TR> The following patch fixes it for me, but I'm not sure if it is the right
TR> thing to do. For me it looks like sa-learn doesn't accept "From " alone
TR> as message seperator anymore, so i added "nobody" and the current time
TR> string. I'm on Debian Sid FWIW (SpamAssassin version 3.3.1).

TR> Could someone more knowing about the issue comment on this?

This looks OK to me.  I pushed it, can you double-check?

Thanks
Ted




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: spam.el + sa-learn
  2011-01-19 21:32 ` Ted Zlatanov
@ 2011-01-22  9:59   ` Tom Rauchenwald
  0 siblings, 0 replies; 3+ messages in thread
From: Tom Rauchenwald @ 2011-01-22  9:59 UTC (permalink / raw)
  To: ding

Ted Zlatanov <tzz@lifelogs.com> writes:

> On Mon, 17 Jan 2011 20:50:57 +0100 Tom Rauchenwald <sehnsucht.nach.unendlichkeit@quantentunnel.de> wrote: 
>
> TR> i recently noticed that my spamassassin bayes database didn't get
> TR> updated properly. sa-learn didn't pick up messages I fed it (via the
> TR> spam exit processors).
>
> TR> The following patch fixes it for me, but I'm not sure if it is the right
> TR> thing to do. For me it looks like sa-learn doesn't accept "From " alone
> TR> as message seperator anymore, so i added "nobody" and the current time
> TR> string. I'm on Debian Sid FWIW (SpamAssassin version 3.3.1).
>
> TR> Could someone more knowing about the issue comment on this?
>
> This looks OK to me.  I pushed it, can you double-check?
>
> Thanks
> Ted

Thanks & thanks for providing a proper commit message.

It looks okay from my end.

-tom

-- 
There are two major products that come out of Berkeley: LSD and UNIX.
We don’t believe this to be a coincidence.  
                -- Jeremy S. Anderson




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-01-22  9:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-17 19:50 spam.el + sa-learn Tom Rauchenwald
2011-01-19 21:32 ` Ted Zlatanov
2011-01-22  9:59   ` Tom Rauchenwald

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).