[Spambayes] imap4 filter

Tony Meyer tameyer at ihug.co.nz
Mon Dec 29 00:20:08 EST 2003


> First note that in order to open the configuration web 
> interface I have to run "python scripts/sb_imapfilter.py -b". 

That is correct.  In the next release you can serve the interface without
launching a browser window, but in 1.0a7 you cannot (you can close the
browser window, leave imapfilter running and then open it again).

> The web interface will not open with http://localhost:8880, 

Unless sb_imapfilter.py is running, right?

> possibly because there is no running web server 
> unless the script is executed first?

The sb_imapfilter.py script serves the web interface, yes.  It has to get
there somehow!

> After I log out of the machine it seems that the web server is
> stopped, so presumably the mail isnt being filtered?

That is correct.  sb_imapfilter filters when it is run, and then does
nothing.  You can set it to filter repeatedly, but if you stop it (or don't
set it to repeat), then that's it.

> Heres what I get from the web interface when I select 
> "configure folders to filter":
[...]
>   File 
> "c:\python23\Lib\site-packages\spambayes\PyMeldLite.py", line 499, in 
> feed
>     self._parser.Parse(data)
> 
> ExpatError: not well-formed (invalid token): line 1, column 70

This is a *bad* thing - it means that the ui_html.py file in the spambayes
package is no good.  It works for me here, but I don't have time right at
the moment to grab a copy of 1.0a7 and see if that's because it has been
fixed since (I don't recall that it was, but it's been a while).  Have you
changed this file at all?  Do you have resourcepackage installed (unlikely,
but a possible cause).

> Because the POP3 instructions appear before the IMAP 
> instructions and there isnt a statement saying to skip them if
> youre only using IMAP, this isnt clear. 

Did you also try to use the Outlook instructions before POP3 and the
procmail ones after IMAP <0.5 wink>?  I'll add a line saying to only follow
the relevant section.

> I also had some problems figuring out how to install 
> spambayes after installing python.  When it says to run
> "setup.py install" for instance, this skips some matters. 
> I had to open a command 
> prompt, page through to the folder where the script was located;

This was considered existing knowledge for users (i.e. was implied in "in
the
directory that you expanded the SpamBayes archive into").  I've elaborated
it somewhat, although for users for whom this doesn't come easily, the (soon
to be released) binary version will solve this problem (although the first
release probably won't include imapfilter).

> then I had to use the command "c:\python23\python setup.py install"
> since the executable couldnt otherwise be found.

This depends on how you installed Python.  If python isn't on your path,
then you have to use the full path, otherwise you don't.  Either way, we
can't guess what the correct path will be.  I'm leaving this one, because
IMO if people can't figure this out (you did, obviously) then they shouldn't
be running from source.

=Tony Meyer




More information about the Spambayes mailing list