![]() |
|
FastMail Forum All posts relating to FastMail.FM should go here: suggestions, comments, requests for help, complaints, technical issues etc. |
![]() |
|
Thread Tools |
![]() |
#16 | ||||
Essential Contributor
Join Date: May 2018
Posts: 344
|
Quote:
![]() Quote:
The explicit keep was never necessary since sending the message to the inbox is always the default unless it is cleared explicitly for some reason (i.e., in the section 4 code where it does the discard because a UI rule matched) before execution terminates. Quote:
Quote:
For code following section 4 the only conditions I can think of where you might not want it subject to the stop switch is where you are 100% sure no match could possibly ever have occurred in section 4 which is what I think you are assuming. I suppose it's ok not to prefix with the stop switch test or use the else/elsif but why would you not want to? Then you don't fall into problems like yours and having to keep track that anything you do down there doesn't conflict with some UI filter you may add in the future. But if you want to leave everything as is except for that keep so be it. Last edited by xyzzy : 16 Mar 2021 at 11:31 AM. |
||||
![]() |
![]() |
![]() |
#17 |
Cornerstone of the Community
Join Date: Jul 2002
Location: Tacoma, WA
Posts: 606
|
As you can probably tell from what I've written before, my knowledge of Sieve is rather limited, and I appreciate the time you've been taking to stick with me on this.
I do have a couple of other questions... (A) To make sure I understand what you are suggesting as one possible way to proceed: Replace Code:
if string :is "${stop}" "Y" { # For backwards compatibility } Code:
if string :is "${stop}" "Y" {stop;} (B) If you look back at my earlier post where I pasted the entire section 4, you'll notice that I have two rules. One of them is the rule we've been talking about where a copy was retained in the Inbox. But the other one is a very similar rule, but does NOT result in a copy being retained. I would think the two rules ought to display similar behavior! The only difference I can see is that one rule tries to filter only on the From address, while the other filters on the To address + Subject. |
![]() |
![]() |
![]() |
#18 | ||
Essential Contributor
Join Date: Dec 2017
Location: Scotland
Posts: 256
|
Quote:
Edited: I looked in RFC 5228 - see: https://tools.ietf.org/html/rfc5228 - where in section 2.10.6 it says: "When an error occurs in a Sieve script, all processing stops." but then it describes aspects that vary according to the implementation. And then it says "When an error happens, implementations MUST notify the user that an error occurred and which actions (if any) were taken, and do an implicit keep." I am not sure (if there is a problem) how that notification of the user might happen. But note that it's another way that a "keep" could happen. Quote:
One solution to this - since you seem not to understand Sieve very well - would be to stop using your own Sieve code. Are you certain that whatever your custom code does cannot done by setting up rules within the FM rules GUI? Last edited by JeremyNicoll : 17 Mar 2021 at 12:43 AM. |
||
![]() |
![]() |
![]() |
#19 | |||
Essential Contributor
Join Date: May 2018
Posts: 344
|
Quote:
Code:
### 4. User configured rules . . . if string :is "${stop}" "Y" { # For backwards compatibility } ----------------------------------------------- end of section 4 ----------------------------------------------- start of your code at the bottom if string :is "${stop}" "Y" {stop;} # <-- add this line before your original code your original code starts here... ... Code:
if test1 { stuff to do if test1 is true... } elsif test2 { stuff to do if test2 is true... } elsif test3 { stuff to do if test3 is true... } Either way it's simple quick fix. Quote:
Quote:
Is it the match criteria? Remember that creating rules in the UI gives you two ways to create a rule. One is the "search" type of rule. The other is the "no preview" method which gives you more matching criteria. Is it the actions? If so then, yes, I suppose then you might need your own code. Last edited by xyzzy : 17 Mar 2021 at 07:19 AM. |
|||
![]() |
![]() |
![]() |
#20 | |
Cornerstone of the Community
Join Date: Jul 2002
Location: Tacoma, WA
Posts: 606
|
Quote:
Thanks for all your help! |
|
![]() |
![]() |
![]() |
Thread Tools | |
|
|