New feature: Handling errors in actions

New feature: Handling errors in actions

The principle of Continuous Integration is simple: make changes > test for errors > integrate with code if everything is okay / fix bugs and test again if something's wrong. In Buddy, these tasks are performed by pipeline actions. If something goes wrong (e.g. the tests fail), Buddy will stop the pipeline and mark the responsible action as failed. One should never merge a branch with errors: this is an impassable rule that should never be violated and this is why we never allowed the pipeline to continue if an action was failing.

However, the rule does not apply to all actions that Buddy has to offer. For example, you can create a CI pipeline with a Slack action in the end. Let's assume Slack failed to deliver the message for one reason or another: even though it happened, the most important part is that the tests have passed, so the pipeline should still finish as successful. This is where you can apply our new feature: the way errors are handled.

Configuration

The feature is available in the Action tab of the action details:

Image loading...Defining error handling

Once it's selected, Buddy will continue to execute the pipeline even if the selected action has failed. The action will be marked with a small warning sign on the execution details:

Image loading...Failed action on the execution view

Warning
The above screenshot is just an example – you certainly DO NOT want to proceed if CodeSniffer sniffed errors in your code! :)
Hint
If you are using submodules in your project, the warning state will be automatically applied in the Prepare environment step in case of errors during the submodule fetch.

The sign will also be visible on the affected pipeline:

Image loading...Pipeline wih error

Jarek Dylewski

Jarek Dylewski

Customer Support

A journalist and an SEO specialist trying to find himself in the unforgiving world of coders. Gamer, a non-fiction literature fan and obsessive carnivore. Jarek uses his talents to convert the programming lingo into a cohesive and approachable narration.

Feb 20th 2020
Share