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

withStatusContext breaks default pipeline behavior #22

Open
quarckster opened this issue May 26, 2019 · 2 comments
Open

withStatusContext breaks default pipeline behavior #22

quarckster opened this issue May 26, 2019 · 2 comments
Assignees

Comments

@quarckster
Copy link
Contributor

Current implementation dry method in withStatusContext breaks default pipeline behavior. The default behavior is to abort further execution of the pipeline if some stage failed. In job logs I can see hudson.AbortException: script returned exit code 1. This exception should abort further execution but it's caught instead. I believe it's incorrect behavior.

@bsquizz
Copy link
Collaborator

bsquizz commented May 26, 2019

It's actually intended behavior so that if, for example, lint fails, then the unit tests or other tests will still run, so that you don't end up fixing lint problems to only discover now you have unit test problems :)

Perhaps we could add an optional flag to the function that aborts immediately if the caller desires?

@quarckster
Copy link
Contributor Author

From my perspective default behavior should abort a stage in case any error. It's common for other CI services such as Travis, Gitlab CI and so on. If we introduce this optional flag it should bypass abortion.

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

2 participants