Шукати в статтях підтримки

Остерігайтеся нападів зловмисників. Mozilla ніколи не просить вас зателефонувати, надіслати номер телефону у повідомленні або поділитися з кимось особистими даними. Будь ласка, повідомте про підозрілі дії за допомогою меню “Повідомити про зловживання”

Докладніше

Ця тема перенесена в архів. Якщо вам потрібна допомога, запитайте.

Filters executing in the wrong order, but only when running automatically (not manual force)

  • 2 відповіді
  • 1 має цю проблему
  • 2 перегляди
  • Остання відповідь від Adam Reece | WebBox

more options

Hello,

I have a subset of message rules which do not appear to execute in the right order, or the function to stop filter execution once a rule is met is not happening. This only happens when filters run automatically for new messages. Filters execute as expected when doing so manually either via "Tools > Run Filters on Folder" or in the filters management UI.

I saw a related issue: https://support.mozilla.org/en-US/questions/1299994 However this turned out to be a GUI bug whereby the message filters data file had `enabled="no"` but the GUI showing all filters were enabled. That is not the case for me.

I've included a subset of the "msgFilterRules.dat" involved at the end. You'll find a collection of rules to move messages to various sub-folders within a "Servers" folder, along with a final rule to put messages in the "Servers" folder itself. The intention here is that the more fine grained subfolder rules should be matched first, and if matched, don't look any further.

What happens is when messages arrive in my inbox the final rule is the one that seems to get the say. (E.g. messages with reply-to being "cpanel@" end up in the main "Servers" folder instead of "Servers/cPanel" folder. However after this first move, if I select the main "Servers" folder then do "Tools > Run Filters on Folder" the rule for cPanel messages works as expected. This would either be because the final rule won't match because Thunderbird thinks its already fulfilled, or the function to stop filter execution just doesn't work.

Is this a bug or have I just got rules defined incorrectly for the intention?

    1. msgFilterRules.dat

name="Servers: cPanel" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/cPanel" action="Stop execution" condition="AND (\"reply-to\",contains,cpanel@) AND (to,is,[email protected])" name="Servers: Firewall" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/Firewall" action="Stop execution" condition="AND (subject,begins with,lfd on) AND (to,is,[email protected])" name="Servers: Hosting accounts (LVM)" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/Hosting Accounts" action="Stop execution" condition="OR (subject,begins with,Hosting account resources exceeded) AND (to,is,[email protected])" name="Servers: Logwatch" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/Logwatch" action="Stop execution" condition="AND (subject,begins with,Logwatch for) AND (to,contains,[email protected])" name="Servers: Pinger" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/Pinger" action="Stop execution" condition="OR (to,is,[email protected]) OR (\"reply-to\",is,[email protected])" name="Servers: Webmin" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers/Webmin" action="Stop execution" condition="AND (\"reply-to\",contains,webmin@) AND (to,is,[email protected])" name="Servers" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%40example.com@imap.example.com/Servers" action="Stop execution" condition="OR (to,is,[email protected]) OR (from,is,[email protected])"

Hello, I have a subset of message rules which do not appear to execute in the right order, or the function to stop filter execution once a rule is met is not happening. This only happens when filters run automatically for new messages. Filters execute as expected when doing so manually either via "Tools > Run Filters on Folder" or in the filters management UI. I saw a related issue: https://support.mozilla.org/en-US/questions/1299994 However this turned out to be a GUI bug whereby the message filters data file had `enabled="no"` but the GUI showing all filters were enabled. That is not the case for me. I've included a subset of the "msgFilterRules.dat" involved at the end. You'll find a collection of rules to move messages to various sub-folders within a "Servers" folder, along with a final rule to put messages in the "Servers" folder itself. The intention here is that the more fine grained subfolder rules should be matched first, and if matched, don't look any further. What happens is when messages arrive in my inbox the final rule is the one that seems to get the say. (E.g. messages with reply-to being "cpanel@" end up in the main "Servers" folder instead of "Servers/cPanel" folder. However after this first move, if I select the main "Servers" folder then do "Tools > Run Filters on Folder" the rule for cPanel messages works as expected. This would either be because the final rule won't match because Thunderbird thinks its already fulfilled, or the function to stop filter execution just doesn't work. Is this a bug or have I just got rules defined incorrectly for the intention? ## msgFilterRules.dat name="Servers: cPanel" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/cPanel" action="Stop execution" condition="AND (\"reply-to\",contains,cpanel@) AND (to,is,[email protected])" name="Servers: Firewall" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/Firewall" action="Stop execution" condition="AND (subject,begins with,lfd on) AND (to,is,[email protected])" name="Servers: Hosting accounts (LVM)" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/Hosting Accounts" action="Stop execution" condition="OR (subject,begins with,Hosting account resources exceeded) AND (to,is,[email protected])" name="Servers: Logwatch" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/Logwatch" action="Stop execution" condition="AND (subject,begins with,Logwatch for) AND (to,contains,[email protected])" name="Servers: Pinger" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/Pinger" action="Stop execution" condition="OR (to,is,[email protected]) OR (\"reply-to\",is,[email protected])" name="Servers: Webmin" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers/Webmin" action="Stop execution" condition="AND (\"reply-to\",contains,webmin@) AND (to,is,[email protected])" name="Servers" enabled="yes" type="17" action="Move to folder" actionValue="imap://adam%[email protected]/Servers" action="Stop execution" condition="OR (to,is,[email protected]) OR (from,is,[email protected])"

Усі відповіді (2)

more options

the stopping of execution only applies to that filter, not the ones that follow it or proceed it.

more options

Hi Matt,

That would explain it. Kind of makes the action pointless to have at the end of a filter set. Given that the filers UI doesn't let you rearrange actions without removing/re-adding them that just adds to the confusion of the UI.

I take it there isn't an option to stop all filter execution once a particular rule is matched? The generic catch rule at the end is there to stop messages being moved twice (what with Gmail over IMAP being very slow).

Possibly related: https://support.mozilla.org/en-US/questions/1034337

Змінено Adam Reece | WebBox