[Spambayes] IMAPFilter training issues (WAS imapfilter mangling headers!)

Tim Stone - Four Stones Expressions tim at fourstonesExpressions.com
Tue Apr 22 12:42:50 EDT 2003

4/22/2003 10:22:42 AM, Oliver Maunder <lists at olivermaunder.co.uk> wrote:

>UPDATE:  Just done some more debugging, and the regex match seems to be 
>failing in IMAPFolder.keys(). My server returns responses like
>83 (FLAGS (\Seen) UID 131)
>whereas the regex is looking for
>r"[0-9]+ \(UID ([0-9]+) FLAGS \(([\\\w]*)\)\)"
>which seems to have things in a different order.

Ok.  That explains it.  That regex is looking for the message id, which is 
used to look in the index to see if that message has already been trained.  
Not finding it, it is ignoring the message altogether.

This is another fluke in imap to add to a growing list of flukes...

Just for fun, change the regex to:
   r"[0-9]+ \(FLAGS \(([\\\w]*)\) UID ([0-9]+)\)"
and see what happens...
>I'm getting a growing feeling that my ISPs mailserver is very badly 
>behaved indeed!

Ain't no such thing as a well behaved imap server.

c'est moi - TimS

There are 10 kinds of people in the world:
  those who understand binary,
  and those who don't.

More information about the Spambayes mailing list