-
Bug
-
Resolution: Not A Defect
-
Major
-
master: centos 7 + java (openjdk) 1.8.0_151 + jenkins 2.46.3 (plugins up to date as of 2017-11-19)
slave: ubuntu 14 LTS + java (oracle) 1.8.0_151
I have a matrix based job where some of the jobs are marked as failure even thought the shell steps exits with 0 code.
These are the last lines of the output console when the job fails.
{{ + exitcode=0}}
{{ + exit 0}}
{{ ++ '[' 1 = 1 ']'}}
{{ ++ '[' -x /usr/bin/clear_console ']'}}
{{ ++ /usr/bin/clear_console -q}}
{{ Build step 'Execute shell' marked build as failure}}
{{ Archiving artifacts}}
{{ Sending e-mails to: xxxxx@xxxxx}}
{{ Finished: FAILURE}}
{{ The Execute Shell script last lines are:}}
# if there were errors, exit code will be greater than zero.
# and the build will fail.
exitcode=$(wc -c stderr.out | cut -f 1 -d ' ')
exit $exitcode
The jobs that succeed have an output like this:
{{ + exitcode=0}}
{{ + exit 0}}
{{ ++ '[' 2 = 1 ']'}}
{{ Archiving artifacts}}
{{ Sending e-mails to: xxxxx@xxxxx}}
{{ Finished: SUCCESS}}
{{ }}
This issue occurs with no apparent reason.