-
Bug
-
Resolution: Not A Defect
-
Critical
-
None
-
Jenkins 2.46.2
MSbuild Plugin 1.27
MSBuild version 14.0
I have a MSBuild project that batch processes a list of projects and I have the task set there to ContinueOnError as I need all the projects to be compiled.
In Jenkins I DO NOT have the Plugin configured to Continue Job on build Failure.
During build an error occurs but the failure is not Failing the build when MSBuild is done and returns to Jenkins the Plugin is not failing out.
MSBuild is reporting 12 Errors on exit but the plugin just lets the job continue, job status at that time is also not Failure.
These particular errors are somewhat unusual as they are from Postsharp and have a line that beings like this:
20>unknown : error : error: Unhandled exception
Not sure if that is the issue or not.
Hello,
I think that since your msbuild task is set to continue on error, msbuild return code is 0 (success) even when one of the build failed. The plugin checks this return code to determine if msbuild succeeded or failed so it thinks there were no error and let the build process continue.
You could either alter your msbuild project so that it returns an error when one of the build has failed or maybe take a look at some other Jenkins plugins that would fail the build based on some regex when postsharp errors appear.