Skip to content

Feature Request: Add onError callback #128

Description

@sbamniya

Allow adding onError callback and that should only be called on error, with the details of the error.

The problem with current implementation is if stopOnError is set to false, it keep working, but we don't know if the callback was failed. We can add try/catch in the callback, but that would add lot of boilerplate code.

It will be helpful when we want to do certain task if the callback is failed, for example, I want to log the error to a third party service like datadog or newrelic, or I want to stop the execution of this method if the it failed for the 3 time continuously.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions