[spambayes-dev] Sb_server crash on training (Last change to Corpus might be the problem)

papaDoc papaDoc at videotron.ca
Sun Mar 21 10:58:41 EST 2004


Hi everyone,

I'm using sb_server
SpamBayes POP3 Proxy Version 0.4 (February 2004)
and engine SpamBayes Engine Version 0.3 (January 2004).

More precisely:
from cvs of the 18 or 19/03/2004

When I try to train on message I get the following error:
This is the traceback from the web page
Traceback (most recent call last):

  File "c:\Devtools\spambayes\spambayes\spambayes\Dibbler.py", line 465, 
in found_terminator
    getattr(plugin, name)(**params)

  File "c:\Devtools\spambayes\spambayes\spambayes\ProxyUI.py", line 392, 
in onReview
    fromCache=True)

  File "c:\Devtools\spambayes\spambayes\spambayes\Corpus.py", line 206, 
in takeMessage
    print "Corpus:takeMessage: options=%s" % options["Headers", header_opt]

TypeError: not enough arguments for format string



I try to add some print statement since in the code their is a warning
                # For Python 2.2, which doesn't allow "string in string".
but I'm using Python 2.3.2 on Windows 2k


####################################
First try
         print "Corpus:takeMessage: Ici 1"
            for header, header_opt in (("Subject", "notate_subject"),
                                       ("To", "notate_to")):
                print "Corpus:takeMessage: Ici 4"
                print "Corpus:takeMessage: options=%s" % options
                print "Corpus:takeMessage: header_opt=%s" % header_opt
#                print "Corpus:takeMessage: options[Headers]=%s" % 
options["Headers"]
#                print "Corpus:takeMessage: options=%s" % 
options["Headers", header_opt]
                print "Corpus:takeMessage: Ici 4.1"

Corpus:takeMessage: Start
Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 2
Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 4
Corpus:takeMessage: options=<spambayes.OptionsClass.OptionsClass object 
at 0x008
95770>
Corpus:takeMessage: header_opt=notate_subject
Corpus:takeMessage: Ici 4.1


####################################
Second try
          print "Corpus:takeMessage: Ici 1"
            for header, header_opt in (("Subject", "notate_subject"),
                                       ("To", "notate_to")):
                print "Corpus:takeMessage: Ici 4"
                print "Corpus:takeMessage: options=%s" % options
                print "Corpus:takeMessage: header_opt=%s" % header_opt
                print "Corpus:takeMessage: options[Headers]=%s" % 
options["Headers"]
#                print "Corpus:takeMessage: options=%s" % 
options["Headers", header_opt]
                print "Corpus:takeMessage: Ici 4.1"

Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 2
Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 4
Corpus:takeMessage: options=<spambayes.OptionsClass.OptionsClass object 
at 0x008
95770>
Corpus:takeMessage: header_opt=notate_subject
(Nothing printed ???)
I get back the web page with no error but the message was not train
(i.e. still in the unsure section).


####################################
Third try
            print "Corpus:takeMessage: Ici 1"
            for header, header_opt in (("Subject", "notate_subject"),
                                       ("To", "notate_to")):
                print "Corpus:takeMessage: Ici 4"
                print "Corpus:takeMessage: options=%s" % options
                print "Corpus:takeMessage: header_opt=%s" % header_opt
#                print "Corpus:takeMessage: options[Headers]=%s" % 
options["Headers"]
                print "Corpus:takeMessage: options=%s" % 
options["Headers", header_opt]
                print "Corpus:takeMessage: Ici 4.1"
Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 2
Corpus:takeMessage: Ici 1
Corpus:takeMessage: Ici 4
Corpus:takeMessage: options=<spambayes.OptionsClass.OptionsClass object 
at 0x008
95770>
Corpus:takeMessage: header_opt=notate_subject

This is the traceback from the web page
Traceback (most recent call last):

  File "c:\Devtools\spambayes\spambayes\spambayes\Dibbler.py", line 465, 
in found_terminator
    getattr(plugin, name)(**params)

  File "c:\Devtools\spambayes\spambayes\spambayes\ProxyUI.py", line 392, 
in onReview
    fromCache=True)

  File "c:\Devtools\spambayes\spambayes\spambayes\Corpus.py", line 206, 
in takeMessage
    print "Corpus:takeMessage: options=%s" % options["Headers", header_opt]

TypeError: not enough arguments for format string




Since this is above my head I give you the problem but I'm ready to do the
testing.


Remi

-- 
/"\
\ /
 X   ASCII Ribbon Campaign
/ \  Against HTML Email




More information about the spambayes-dev mailing list