Re: Problems installing and configuring SpamBayes

[email protected]
Newsgroups gmane.mail.spam.spambayes.general
Message-ID <[email protected]>
    lilliana> I downloaded SpamBayes today, but can't figure out how to use
    lilliana> it.  I clicked on the installing SpamBayes link in your
    lilliana> documentation section, but I got "The connection was reset"
    lilliana> error message....

    lilliana> 500 Server error
    lilliana> Traceback (most recent call last):
    ...
    lilliana> UnboundLocalError: local variable 'state' referenced before assignment

Well, there is clearly a bug in that function which I can fix easily enough.
I'm mystified why it's never been encountered before.  You appear to be
using Windows Live Mail, which might or might not work with SpamBayes.

Unfortunately, I can't make a new release for Windows.  How are you with
Notepad?  Do you think you can find the file sb_server.py and edit it?  The
fix is a one-line change.  Just search for "def _recreateState", then right
after that line, add this line:

    global state

(indented with four spaces, just as I have it above).  So, that bit of code
will change from

def _recreateState():
    # Close the existing listeners and create new ones.  This won't
    # affect any running proxies - once a listener has created a proxy,

to

def _recreateState():
    global state
    # Close the existing listeners and create new ones.  This won't
    # affect any running proxies - once a listener has created a proxy,


Of course, this might not be the only bug.  Given that we've apparently not
seen it before and it appears you're using a rare-for-SpamBayes mail
program, I'd rate the odds of encountering more problems as at least
"moderate".

-- 
Skip Montanaro - [email protected] - http://www.smontanaro.net/
_______________________________________________
[email protected]
http://mail.python.org/mailman/listinfo/spambayes
Info/Unsubscribe: http://mail.python.org/mailman/listinfo/spambayes
Check the FAQ before asking: http://spambayes.sf.net/faq.html
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.