* Re: spam-stat.el -- filtering spam based on statistics as suggested by Paul Graham
[not found] ` <87znv5fqlz.fsf@emacswiki.org>
@ 2002-09-01 0:37 ` Alex Schroeder
0 siblings, 0 replies; 2+ messages in thread
From: Alex Schroeder @ 2002-09-01 0:37 UTC (permalink / raw)
Hm, I've been using it in my .gnus for a while now, and I get errors
in nnml-split-fancy when I use the following setup. This setup does
some spam filtering beforehand, then it uses the BBDB to split, and
then at very end, I try to figure out wether the remaining mail should
go into mail.misc or mail.spam. This is where I use the split
(: spam-stat-split-fancy). The errors, however, results in several mails
getting split into the bogus group. Does anybody know what is wrong
with my code? Suggestions as to debug it? Maybe wrap the body of
spam-stat-split-fancy in a condition-case or something?
Perhaps this is related to some problems with cl.el specific functions
being used without a (require 'cl) in the file in Emacs? At startup
that could mean that these functions fail, but after a while cl.el is
loaded and the error disappears?
Alex.
(setq nnmail-crosspost nil
nnmail-split-methods 'nnmail-split-fancy
bbdb/gnus-split-default-group nil
bbdb/gnus-split-nomatch-function nil
bbdb/gnus-split-myaddr-regexp gnus-ignored-from-addresses
nnmail-expiry-wait 28
gnus-total-expirable-newsgroups
(regexp-opt '("mail.guile"
"mail.gnutella"
"mail.emacs.devel"
"mail.emacs.ilisp"
"mail.frieden.jetzt"
"mail.baeckeranlage"))
nnmail-split-fancy
`(| ("Gnus-Warning" "This is a duplicate" "mail.spam.duplicates")
;; spam filtering based on spam assassin
;; ("X-Spam-Flag" "YES" "mail.spam")
("X-Spam-Level" "\\*\\*\\*\\*\\*\\*\\*" "mail.spam")
;; computer challenged people I know sending me HTML mails
("From" "Sarah Leiken" "mail.family")
;; remaining HTML only mail is spam
("Content-Type" "text/html" "mail.spam")
;; weird character sets are spam, too
("Subject" "=?ks_c_5601-1987" "mail.spam")
;; virus detection is spam
("Subject" "^Norton AntiVirus detected" "mail.spam")
;; temporary spam stuff
(any "machine365.com" "mail.spam")
;; now use the BBDB to split
(: (lambda ()
(car (bbdb/gnus-split-method))))
;; some of the packages I maintain
("Subject" "\\(color-theme\\|ansi-color\\)" "mail.emacs")
;; spam filtering based on statistics
(: spam-stat-split-fancy)
;; mail from and to me, mail to any of the emacswiki addresses
(any ,gnus-ignored-from-addresses "mail.misc")
(any ".*@emacswiki.org" "mail.emacs.wiki")
;; anonymous mail, probably spam
"mail.spam"))
^ permalink raw reply [flat|nested] 2+ messages in thread