-
Notifications
You must be signed in to change notification settings - Fork 351
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
task error handling #3525
Comments
perhaps a better way to name this would be "cleanup" and not worry about catching errors |
Maybe add the ability to only trigger the failure case on a specific exit code ? |
I was going to pass the status code as an env var |
The status code should be available in $? in my opinion for use in cleanup. |
setting that before a script runs is complicated and something that would have to be unique depending on which shell is being used. Imagine a handler being written in python, for example. |
Ah, you are correct. TIL: https://stackoverflow.com/a/26627346 |
there should be some kind of error handling to execute something when a task fails, perhaps to cancel the error somehow. My use-case for this is I have a bunch of tasks that run and leave the project in an inconsistent state when they fail because it's all running in parallel. There is a specific task that—if failed—I'd like it to reset the contents of a specific file.
Noodling on this:
I don't personally need to cancel the error—though I feel like with this sort of thing that's probably going to be behavior someone wants—especially if I call this "error handling".
Maybe we could make that an optional setting:
what do other task managers do?
The text was updated successfully, but these errors were encountered: