Question about setting Build Status to FAILURE

I have a Build Configuration whose first Build Step is calling a command line program which sets the Build Status to FAILURE (by printing the line ##teamcity[buildStatus status='FAILURE' text='{{build.status.text}}']).  However, my second Build Step is still being called even though the build has Failed.  Should the build be stopping as soon as it reads the FAILURE message, or is there something else I need to do in order for it to not continue on to the next step?

Note:  I am aware that I could create a seperate Build Configuration that is conditional to the first Build Configuration not Failing, but I would prefer not to do that.

Thanks,
~Alex

3 comments
Comment actions Permalink

Hi Alex

This issue was reported in TW-17015, please vote and watch.
As workaround, in addition to the service message please set exit code for this build step.

0
Comment actions Permalink

Michael,

Thanks for the answer.  I will structure my code to return an Exit Code along with the error message.

~Alex

0
Comment actions Permalink

Double Post.  Had error and first wasn't showing up.

Message was edited by: Alex Yeisley

0

Please sign in to leave a comment.