🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #264628

Re: Using logical opeartors in Dialog Filters

#264628
From: Bernd Rose
Date: Thu, 21 Jan 2021 16:51
35 lines
2678 bytes
On Wed, 20th Jan 2021 12:31:23 -0600, VanguardLH wrote:

> I was pondering if what I wrote about the +@ and -@ where correct.  

Yes. The +@ can be considered as "AND" and -@ as "AND NOT". To get "OR",
several separate scoring lines have to be written.

> I have run across where a multiple header rule doesn't fire, everything
> looked correct, testing on individual header clauses in the rule would
> work in the regex tester on the header string, so I had to come up with
> different rule(s) to effect what I was trying to accomplish within one
> rule.  Mostly I try to stick to just one additional header, like: 
> 
>   From {...} -@Message-ID:{....}
> 
> because sometimes I have used 3, or more, headers in a rule, like:
>  
>   From {...} -@Message-ID:{...} +Header:{^Path: ...}
>   
> and the rule doesn't fire.  Seems if it gets too complicated then the
> rule gets missed.  Or maybe it's the 2-pass scheme when exercising
> rules, and I'm mixing overview and non-overview rules in the same rule.
> I've not narrowed down why a 3+ multiple-header rule doesn't fire
> despite in header clause with the rule works by itself.

You missed the "@" char between "+" and "Header". In general, multiple
conditions /can/ be defined. As an example, the following works in this
group:

!setcolor(green;yellow) From "Bernd Rose" -@Message-ID: {b\.rose[^ ]*\.(uk|com)} +@Header: "User-Agent: 40tude_Dialog"

Too complicated rules /are/ prone to error, though.  ;-)

HTH.
Bernd
Technical Details
Message-ID: <1fz8tnrbm7g3g$.dlg@b.rose.tmpbox.news.arcor.de>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
References: <lo1iu4iamqxs$.dlg@sqwertz.com> <ie3bbwuzo6wp.dlg@v.nguard.lh> <ru6rve.ars.1@ID-201911.user.individual.net> <1aa8twtz0lrzb$.dlg@v.nguard.lh> <ru7ed9.lk8.1@ID-201911.user.individual.net> <18r629zo0t48b.dlg@v.nguard.lh> <z882tgbtf5z3.dlg@b.rose.tmpbox.news.arcor.de> <1na89nr1j05zy.dlg@v.nguard.lh>

Show Full Headers
Complete Article Headers
Message-ID: <1fz8tnrbm7g3g$.dlg@b.rose.tmpbox.news.arcor.de>
Subject: Re: Using logical opeartors in Dialog Filters
Date: Thu, 21 Jan 2021 17:51:42 +0100
From: Bernd Rose <b.rose.tmpbox@arcor.de>
References: <lo1iu4iamqxs$.dlg@sqwertz.com> <ie3bbwuzo6wp.dlg@v.nguard.lh> <ru6rve.ars.1@ID-201911.user.individual.net> <1aa8twtz0lrzb$.dlg@v.nguard.lh> <ru7ed9.lk8.1@ID-201911.user.individual.net> <18r629zo0t48b.dlg@v.nguard.lh> <z882tgbtf5z3.dlg@b.rose.tmpbox.news.arcor.de> <1na89nr1j05zy.dlg@v.nguard.lh>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
Mime-Version: 1.0
Injection-Info: solani.org; logging-data="30491"; mail-complaints-to="abuse@news.solani.org"
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Cancel-Lock: sha1:CM8flN13pvPgLh4dBXDJ6uwGQh4=
User-Agent: 40tude_Dialog/2.0.15.41 (e3a4aaef.238.326)
X-User-Id: eJwNy8EBwCAIA8CVEAjCOGLJ/iPU/x0sVtztgXAQnG9z96VW09t8LKEmKqAeQykGnSeJGmixOF03ZakfB3L112sLH+1X8gfaKhms
Newsgroups: news.software.readers