Closed Gazoo closed 5 years ago
It looks like that block of code was taken from a very old HashBl.pm. Why not use the updated code that is included by default in the new SpamAssassin?
https://github.com/apache/spamassassin/blob/trunk/lib/Mail/SpamAssassin/Plugin/HashBL.pm#L251
Could you confirm that replacing the $self->{email_re} in SH.pm with the one from HashBL.pm (from SpamAssassin trunk) solves the problem? I don't have a system like your to test it and I'd prefer to wait for 3.4.3 to be officially released before debugging on a release candidate
Unfortunately changing $self->{email_regex} to the code from HashBL.pm $self->{email_re} doesn't fix it. I wonder why the HashBL.pm code works fine while the code in SH.pm doesn't ?
Alright, I managed to reproduce the problem. If you do a
spamassassin --lint -D
You'll probably see the lines:
Jul 19 15:34:50.457 [63775] dbg: HashBL: local tests only, disabling HashBL Jul 19 15:34:50.405 [63775] dbg: SHPlugin: local tests only, disabled
The problem is that our plugin doesn't handle very nicely not having network tests enabled, so it throws that error.
I now pushed a fixed version (also with the better email regex, thanks for pointing that out) , but you should check why you have network checks disabled
We don't have network tests disabled. Doesn't spamassassin --lint disable network tests automatically? As you can see from our spam stats Pyzor, Razor2, and HashBL all are working without issue.
Maybe something changed on 3.4.3 .. the error was because the function $self->{main}->{registryboundaries}->{valid_tlds_re} apparently doesn't load when linting (that could make sense if network tests are disabled)
However, did you fetch the latest SH.pm and tried?
The updated version doesn't spit out any error now when running spamassassin --lint
with SpamAssassin 3.4.3 RC3
Also running spamassassin --lint -D
Jul 19 08:17:21.145 [27428] dbg: SHPlugin: local tests only, disabled
Looks like its fixed. Thanks again!
closing this, thanks to you again for pointing out the outdated regex :)
After installation I get this when running
spamassassin --lint
OS version:
SpamAssassin version: