[Spambayes] Problems getting started with IMAP...
Paul Michali
pcm at cisco.com
Mon Apr 26 08:08:44 EDT 2004
Tony Meyer wrote:
>>I applied this patch and deleted the .pyc file just in case.
>>However, when I try the stats, I still get the same error:
>>
>
> [...]
>
>>AttributeError: 'NoneType' object has no attribute 'keys'
>>
>>Is there something else that needs to be updated?
>
>
> Hmm, odd. Maybe that wasn't the problem (although it was *a* problem).
> Could you try:
>
> 1. In your configuration file, add a "[globals]" section (if there isn't
> already one) and in that section add "verbose:True". When you run
> sb_imapfilter.py, do you now get a "Warning: no dbm modules available" error
> printed out? (You shouldn't, because it shouldn't be trying use use dbm,
> but it would explain why msginfoDB is None).
Nope. I get this:
Loading state from hammie.db pickle
hammie.db is an existing pickle, with 350 ham and 2816 spam
Loading database hammie.db... Done.
>
> 2. In the same place in message.py (line 214, I think) as the previous
> patch, add a line just after that stuff that has:
>
> """
> print options["Storage", "persistent_use_database"], msginfoDB
> """
>
> This should print out something like "pickle <MessageInfoPickle object at
> ...>", if all is well.
Hmm. I added that line (indented four spaces), right after
the if clause, but I don't see any message displayed in
the Web page or on the console output. Am I doing anything
wrong?
>
>>I start it on the Unix box in the foreground. Enter the
>>IMAP password, then do a "control-Z" and then "bg 1" to
>>put this in the background. It seems to be running, but
>>when I exit the terminal window, it seems that it terminates
>>at some point. I no longer have a console, so I don't know
>>what happened. Any thoughts?
>
>
> Could you run it redirecting stdout & stderr to a file, so that any errors
> are captured?
I'm not quite sure how to do that, as I need to start it in
the foreground so that it asks me the IMAP password, and then
place it into the background. Maybe I can use "tee"? In any
case, the process I started Friday is still running. I haven't
been able to get the problem to reproduce :^(
>>Finally, another question (sorry). Is there a way to have imapfilter
>>detect when new mail arrives at the IMAP server, or does it have to
>>poll for messages?
>
> This is something I would look into if I ever got the time to work on
> imapfilter again (properly, rather than this bugfix sort of stuff). It's
> possible in theory, but I'm not sure how workable it would be. You could
> stay connected, and the server is meant to send out messages with updated
> exists/recent counts when they change. I'm not sure how well implemented
> this is across servers, and how well it works when both the filter and the
> mail client are connected. The filter would still have to cycle through the
> various watch folders, I think, since the updates only get sent out for the
> currently selected folder (unless there was only one watch folder).
It would be nice to have it immediately update, when
messages come it. Then, the "-l" option would not really
be needed and there would be less of a chance where the
client sees the message before it has been classified (if
the filter runs instantly and the client is polling every
10 minutes or so).
>
> It would be a good 1.1 feature, though. Maybe I'll get time to work on
> imapfilter again one day :)
That would be great. If you want someone to test it out, I
can certainly do that.
PCM WORKING @ HOME (Paul Michali)
More information about the Spambayes
mailing list