It’s pretty much the same. The other option is to put a try/catch block around the action. There are often many ways to achieve the same result for something in FinalBuilder.
Actually, now that I think about it, there is a difference, in that the If prev failed action executes it’s children, you know for sure the prev action failed. If you just add those same actions as children of the failing/ignored action, they will run whether the action failed or not, but you will not know what the result was.
If you just add those same actions as children of the failing/ignored action, they will run whether the action failed or not...
-- I'm confused: The children of an action are *only* run if the action succeeds, if the action fails (and has ignore-failure set) the the children will be skipped and the next action will be resumed. Correct?
Yes, but what that doesn’t give you is the ability to run some other actions only when that action fails. So if you want to run actions when the other action fails (with ignore set), use the If Prev action Failed action. If you only want to run actions when an action doesn’t fail, make them a child action.
In a scenario where an action is prone to failure and you don’t want to fail the build, my preference would be to use the Try/Catrch/Finally actions to control the error handling and what runs when. I think that makes the flow of the process easier to understand.
So if you want to run actions when the other action fails (with ignore set), use the If Prev action Failed action. If you only want to run actions when an action doesn't fail, make them a child action.
Excellent explanation, thanks! -- Allow me to suggest to put this sentence into the help of the If-Prev-Action-Failed action :-) --