[Spambayes-checkins]
spambayes/spambayes Options.py,1.18,1.19 OptionConfig.py,1.4,1.5
Tim Stone
timstone4 at users.sourceforge.net
Thu Mar 6 06:13:24 EST 2003
Update of /cvsroot/spambayes/spambayes/spambayes
In directory sc8-pr-cvs1:/tmp/cvs-serv484
Modified Files:
Options.py OptionConfig.py
Log Message:
Added option to disable caching of messages per feature request 690928
Index: Options.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/spambayes/Options.py,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -d -r1.18 -r1.19
*** Options.py 1 Mar 2003 22:45:16 -0000 1.18
--- Options.py 6 Mar 2003 14:13:22 -0000 1.19
***************
*** 390,393 ****
--- 390,394 ----
pop3proxy_notate_to: False
pop3proxy_notate_subject: False
+ pop3proxy_cache_messages: True
# valid options for pop3proxy_add_mailid_to include
# "", "header", "body", and "header body"
***************
*** 507,512 ****
'pop3proxy_persistent_use_database': boolean_cracker,
'pop3proxy_persistent_storage_file': string_cracker,
! 'pop3proxy_notate_to': boolean_cracker,
! 'pop3proxy_notate_subject': boolean_cracker,
'pop3proxy_add_mailid_to' : string_cracker,
'pop3proxy_mailid_header_name' : string_cracker,
--- 508,514 ----
'pop3proxy_persistent_use_database': boolean_cracker,
'pop3proxy_persistent_storage_file': string_cracker,
! 'pop3proxy_notate_to' : boolean_cracker,
! 'pop3proxy_notate_subject' : boolean_cracker,
! 'pop3proxy_cache_messages' : boolean_cracker,
'pop3proxy_add_mailid_to' : string_cracker,
'pop3proxy_mailid_header_name' : string_cracker,
Index: OptionConfig.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/spambayes/OptionConfig.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** OptionConfig.py 1 Mar 2003 22:52:06 -0000 1.4
--- OptionConfig.py 6 Mar 2003 14:13:22 -0000 1.5
***************
*** 46,50 ****
'p3servers': ('pop3proxy', 'pop3proxy_servers'),
'p3ports': ('pop3proxy', 'pop3proxy_ports'),
! 'p3notate': ('pop3proxy', 'pop3proxy_notate_to'),
'p3addid': ('pop3proxy', 'pop3proxy_add_mailid_to'),
'p3stripid': ('pop3proxy', 'pop3proxy_strip_incoming_mailids'),
--- 46,52 ----
'p3servers': ('pop3proxy', 'pop3proxy_servers'),
'p3ports': ('pop3proxy', 'pop3proxy_ports'),
! 'p3notateto': ('pop3proxy', 'pop3proxy_notate_to'),
! 'p3notatesub': ('pop3proxy', 'pop3proxy_notate_subject'),
! 'p3cachemsg': ('pop3proxy', 'pop3proxy_cache_messages'),
'p3addid': ('pop3proxy', 'pop3proxy_add_mailid_to'),
'p3stripid': ('pop3proxy', 'pop3proxy_strip_incoming_mailids'),
***************
*** 87,101 ****
specify the same number of ports as servers, separated by commas."""),
! ("p3notate", "Notate To",
! """Some email clients (Outlook Express, for example) can only set
! up filtering rules on a limited set of headers. These clients
! cannot test for the existence/value of an arbitrary header and filter
! mail based on that information. To accomodate these kind of mail
! clients, the Notate To: can be checked, which will add "spam,",
! "ham,", or "unsure," to the recipient list. A filter rule can then
! test to see if one of these words (followed by a comma) is in the
! recipient list, and route the mail to an appropriate folder, or take
! whatever other action is supported and appropriate for the mail
! classification."""),
("p3addid", "Add id tag",
--- 89,117 ----
specify the same number of ports as servers, separated by commas."""),
! ("p3notateto", "Notate To",
! """Some email clients (Outlook Express, for example) can only
! set up filtering rules on a limited set of headers. These
! clients cannot test for the existence/value of an arbitrary
! header and filter mail based on that information. To
! accomodate these kind of mail clients, the Notate To: can be
! checked, which will add "spam", "ham", or "unsure" to the
! recipient list. Notate Subject: will add the same to the
! start of the mail subject line. A filter rule can then use
! to see if one of these words (followed by a comma) is in the
! this information in filter rules to route the mail to an
! appropriate folder, or take whatever other action is
! supported and appropriate for the mail classification."""),
!
! ("p3notatesub", "Notate Subject",
! ""),
!
! ("p3cachemsg", "Cache Messages",
! """You can disable the pop3proxy caching of messages. This
! will make the proxy a bit faster, and make it use less space
! on your hard drive. The proxy uses its cache for reviewing
! and training of messages, so if you disable caching you won't
! be able to do further training unless you re-enable it.
! Thus, you should only turn caching off when you are satisfied
! with the filtering that Spambayes is doing for you."""),
("p3addid", "Add id tag",
***************
*** 385,389 ****
try:
! nto = parms['p3notate']
except KeyError:
if options.pop3proxy_notate_to:
--- 401,405 ----
try:
! nto = parms['p3notateto']
except KeyError:
if options.pop3proxy_notate_to:
***************
*** 394,397 ****
--- 410,435 ----
if not nto == "True" and not nto == "False":
errmsg += """<li>Notate To: must be "True" or "False".</li>\n"""
+
+ try:
+ nsub = parms['p3notatesub']
+ except KeyError:
+ if options.pop3proxy_notate_sub:
+ nsub = "True"
+ else:
+ nsub = "False"
+
+ if not nsub == "True" and not nsub == "False":
+ errmsg += """<li>Notate Subject: must be "True" or "False".</li>\n"""
+
+ try:
+ cachemsg = parms['p3cachemsg']
+ except KeyError:
+ if options.pop3proxy_cache_messages:
+ cachemsg = "True"
+ else:
+ cachemsg = "False"
+
+ if not nsub == "True" and not nsub == "False":
+ errmsg += """<li>Cache Messages: must be "True" or "False".</li>\n"""
# edit for equal number of pop3servers and ports
More information about the Spambayes-checkins
mailing list