Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running a step should be determined by the success of the step it dependsOn #528

Open
ceelias opened this issue Aug 18, 2021 · 0 comments
Open

Comments

@ceelias
Copy link
Contributor

ceelias commented Aug 18, 2021

Currently, dependsOn determines when one step needs another step to run before it which is useful for how we currently write our integrations. I have noticed a few times where a step that other steps dependsOn fails, it continues to run the dependent steps which will inevitably fail.

If a step truly dependsOn another, it should know if it failed or succeeded to determine whether it should run or not.

In a case I see in Knowbe4, the fetch-users and fetch-training-camps steps dependsOn the fetch-groups step. When fetch-groups fails, it causes the other 2 to fail since they are looking for a map with relevant data. There are some workarounds to solve this such as:

  1. Set the fetch-groups step to be fatal so the integration terminates. This may not be ideal as there are other steps which don't care about groups.
  2. In this case, you could simply do a check to see if the map it expects has any data and if so run it, otherwise skip over everything. This could work but in my opinion isn't the cleanest.

Screen Shot 2021-08-18 at 10 24 55 AM

This would require us to keep track of the status of each step to check against.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant