Debugging Mail.app rules

mail-rulesmail.app

Is there a way to see what Mail.app is doing when it scans messages for rule firing? I have a rules that download bank statements when I get an email from my bank. Since I have multiple accounts, I rely on the account number in the email message. I have a number of rules, each having a filter that says

Message content contains The statement for your account ending in XXXXX is available online for viewing

where XXXXX is the particular account number. The problem is that the first rule always fires no matter what account number is in the message.

Best Answer

Simplify it to

Message content contains 'XXXXX'

& add 'Stop evaluating Rules' as your last action in the Rule.

Or, if the number may possibly occur in other emails, make the rule.

All 
Message content contains 'The statement for your account ending in'  
Message content contains 'XXXXX'

Adding 'Stop evaluating Rules' is a sensible precaution for all rules that should stop at that point.