You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello. If I decide to use core.setFailed(...) but there are code after that runs if it did not fail, do I need to also add a return or does setFailed automatically terminates the Action? It is not clear from the README.
Example logic:
import*ascorefrom"@actions/core";asyncfunctionrun(){if(condition1){core.setFailed("You should not have done that");// Do I need return; here?}do_stuff_on_success();}
The text was updated successfully, but these errors were encountered:
Hey @pllim thanks for the information! setFailed does not automatically terminate the process, you need to do that manually. You can do that via a return, or following an example like our typescript actions
I think the docs here are good now, but if you have an idea for how to improve them, please submit a pr!
Hello. If I decide to use
core.setFailed(...)
but there are code after that runs if it did not fail, do I need to also add areturn
or doessetFailed
automatically terminates the Action? It is not clear from the README.Example logic:
The text was updated successfully, but these errors were encountered: