Re: bug in mailfilter.crm for training: wrong spam training threshold decision (+ extra: code duping / unreachable code fix)

Paolo <[email protected]>
Newsgroups gmane.mail.spam.crm114
Message-ID <20081004192017.GC26719@localhost>
On Mon, Sep 29, 2008 at 05:49:47AM +0200, Ger Hobbelt wrote:
> BZZZZZZT!

hm, how come I'm getting msgs dated < 29/09 now on 04/10? sf.net's queue
hogged beyond limit once again?
 
>  	    classify <:*:clf:> [:text:] /:*:lcr:/ \
> 		    (:*:fileprefix::*:spamcss: :*:fileprefix::*:nonspamcss: )\
>  		    (:classify_status:)
> 
> See what is missing? The '|' pipe symbol!

yes missing 'cause unneeded - we want the status -> :classify_status:

>  		classify <:*:clf:> [:text:] /:*:lcr:/ \
> -		  (:*:fileprefix::*:nonspamcss: :*:fileprefix::*:spamcss: ) \
> +              (:*:fileprefix::*:nonspamcss: | :*:fileprefix::*:spamcss: ) \
>  		  (:classify_status:)
>  		match [:classify_status:] <nomultiline> \
>  			/^#0.* pR: ([-. 0-9]+)/ (:: :pr:)
> -		eval /:@: :*:pr: < :*:thick_threshold: :/
> +            eval /:@: :*:pr: < :*:good_threshold: :/    # was

nope, with the pipe CLASSIFY may fail, hence skip to bottom '}', instead 
we want to read the pR anyway, and we use '/^#0.* pR:.../' to select pR
related to css 0 (ie 1st in list). 

> Conclusion:
> 
> a) I should clean my glasses and maybe splurge on reading lessons
> because I apparently can't do code reviews anymore.

50/50, since I'm doing from memory and might be fully wrong ;)
 
> b) we, ah, um, might benefit from an extended test suite.

agreed. Known test vector, known expected result.

> missing in classify) in mailreaver @ 542 and no!body gets hurt?  :-S

might mean it's right to _not_ have it there - ie it's really by design.

> I must've forgotten to pay the brain bill, 'cause they sure as Hell

or perhaps too much overnight work and some early morning nightmare ;)


-- 
paolo

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.