<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><div class=""><div apple-content-edited="true" class=""><div class=""><br class=""></div></div><div><blockquote type="cite" class=""><div class="">On 22 Apr 2015, at 20:46, Dmitri Zimine <<a href="mailto:dzimine@stackstorm.com" class="">dzimine@stackstorm.com</a>> wrote:</div><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><br class=""></div><div class="">1) if break-on expression contains the reference to task result, like </div><div class="">break-on: <% $.my_task.foo.bar = true %> </div><div class="">but action returns ERROR and task payload is None (desired behavior: don’t puke, evaluate to false and don’t break)</div></div></div></blockquote><div><br class=""></div><div>I’m a little confused now. I remember we discussed it with you already but I’m just trying to see in what cases we may get action result (=> task result) but have action in ERROR state. The only case that I see is when we use “with-items” and part of actions completed successfully by the time that some action (iteration of “with-items”) failed. Then in $.my_task we would be able to provide a partial (incomplete) result consisting of those successful action results. It’s not how it’s supposed to work now though. If at least one action fails then all successful iterations get invalidated too.</div><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">2) if break-on contains the value from (e.g. published variable, updated by other branch of workflow) - desired behavior - evaluate my_global_flag on every iteration: </div><div class="">break-on <% $.my_global_flag = true %></div></div></div></blockquote><div><br class=""></div><div>Yes, that would be cool to do. The implementation I think is not going to be easy though..</div><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">3) a combination of the two</div><div class=""><div class=""><div class="">break-on <% $.my_global_counter > $.my_task.counter %></div></div></div></div></div></blockquote><div><br class=""></div><div>Yes. We need to clarify 1)</div><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><div class=""><div class="">On Apr 22, 2015, at 6:55 AM, Nikolay Makhotkin <<a href="mailto:nmakhotkin@mirantis.com" class="">nmakhotkin@mirantis.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite" class=""><div dir="ltr" class="">So, in this case I guess 'break-on' will work correctly now: <a href="https://github.com/stackforge/mistral/blob/master/mistral/engine/policies.py#L295-L296" class="">https://github.com/stackforge/mistral/blob/master/mistral/engine/policies.py#L295-L296</a></div></blockquote></div></div></div></div></blockquote></div><br class=""></div></div><div class="">Yes, you’re right. It seems like it works now as I described.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div class="">Renat Akhmerov</div><div class="">@ Mirantis Inc.</div></div><div class=""><br class=""></div></body></html>