[Spambayes-checkins] spambayes/Outlook2000 addin.py,1.51,1.52
Tim Peters
tim_one at users.sourceforge.net
Sat Mar 8 17:13:00 EST 2003
Update of /cvsroot/spambayes/spambayes/Outlook2000
In directory sc8-pr-cvs1:/tmp/cvs-serv24249
Modified Files:
addin.py
Log Message:
ShowClues(): List the unique tokens one per line. I had a hard time
reading them all smushed together.
Index: addin.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/Outlook2000/addin.py,v
retrieving revision 1.51
retrieving revision 1.52
diff -C2 -d -r1.51 -r1.52
*** addin.py 7 Mar 2003 06:28:06 -0000 1.51
--- addin.py 9 Mar 2003 01:12:58 -0000 1.52
***************
*** 255,258 ****
--- 255,259 ----
push(escape(msg.as_string(), True))
push("</PRE>\n")
+
# Show all the tokens in the message
from spambayes.tokenizer import tokenize
***************
*** 264,275 ****
msgstore_message.GetEmailPackageObject(strip_mime_headers=True)))
# create a sorted list
! toks = [tok for tok in toks]
toks.sort()
! push("%d unique tokens<br>" % len(toks))
# Use <code> instead of <pre>, as <pre> is not word-wrapped by IE
# However, <code> does not require escaping.
# could use pprint, but not worth it.
for token in toks:
! push("<code>" + repr(token) + "</code>, ")
# Put the body together, then the rest of the message.
body = ''.join(body)
--- 265,277 ----
msgstore_message.GetEmailPackageObject(strip_mime_headers=True)))
# create a sorted list
! toks = list(toks)
toks.sort()
! push("%d unique tokens<br><br>" % len(toks))
# Use <code> instead of <pre>, as <pre> is not word-wrapped by IE
# However, <code> does not require escaping.
# could use pprint, but not worth it.
for token in toks:
! push("<code>" + repr(token) + "</code><br>\n")
!
# Put the body together, then the rest of the message.
body = ''.join(body)
More information about the Spambayes-checkins
mailing list