# This is working: message gets "X-Spam-Language: ja.shift-jis" added to it. add_header all Language _LANGUAGES_ # This is being ignored maybe? ok_languages en ok_locale en # This is supposed to fire but does not: score UNWANTED_LANGUAGE_BODY 3 # This doesn't fire either: header UNWANTED_LANGUAGE_HEADER X-Spam-Language =~ /\bja\b/ score UNWANTED_LANGUAGE_HEADER 3
SpamAssassin
Dear Lazyweb, any ideas on why TextCat doesn't seem to be firing?
5 Responses:
Leave a Reply
At the risk of stating the absolute obvious, you are loading the plugin in init.pre...?
Also, I think around v3.4 ok_languages got nerfed, and ok_locales took over. I assume a copy/paste error, but your ok_locale is singular, while the doc says plural.
At least you can get _LANGUAGES_ to work. Mine is always empty.
Well as I said, it is identifying the language, so that strongly suggests the plugin is loaded. I tried both ok_ versions.
If it's enabled in init.pre (or another .pre), and you have set ok_languages and ok_locales (plural), then the only other thing I can suggest is the length of body text in your test mails.
Mine did not fire at all for me (i.e. nothing in _LANGUAGES_, no score) for the small, single- or dual-sentence emails I was using to test, just now. I started getting both when I sent myself test mails with a few paragraphs in them.
(The only hint I got to that was spamassassin -D --lint buries a series of lines saying "I need to make this message body somewhat long so TextCat preloads" over and over.)
Not sure what the threshold is. For mails ~100 chars, I got nothing; for mails ~2K chars, I got both.
I have no help to offer, but I am very amused that you are having a shootout with the ok_locale.
Which version of spamassassin is yours? I asume 4.0.
According to https://spamassassin.apache.org/full/4.0.x/doc/Mail_SpamAssassin_Conf.html ok_locale should be written ok_locales, besides the default would be set to all.