Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Builds are tagged unstable even when they are successful

I am running Jenkins version 1.411 and use Maven for building.

Even though the application builds successfully, Jenkins treats it as an unstable build. I have disabled all tests to isolate the problem.

[INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 45.389s [INFO] Finished at: Wed May 11 12:16:57 EST 2011 [INFO] [DocLinks] Skip document Adaptiv generated site ... (No such directory: site) Final Memory: 27M/543M [INFO] ------------------------------------------------------------------------ channel stopped Archiving artifacts Email was triggered for: Unstable Sending email for trigger: Unstable An attempt to send an e-mail to empty list of recipients, ignored. Finished: SUCCESS 
like image 486
Croydon Dias Avatar asked May 11 '11 02:05

Croydon Dias


People also ask

What does it mean when a build is unstable?

Unstable build: A build is unstable if it was built successfully and one or more publishers report it unstable. For example if the JUnit publisher is configured and a test fails then the build will be marked unstable.

Why Jenkins shows unstable build?

The test checking the roslaunch file fails with a stacktrace. That's why the build was marked as unstable and you received a notification email.

How do you mark a Jenkins build unstable?

Jenkins is able to mark the jobs as successful / failed based on exit status. In PHP, the script exits with 1 if it has detected that the tests failed during the run. The other shell scripts run commands and use the exit codes from those to mark a build as failed.

Why is my Jenkins build yellow?

The default setting in Jenkins is to mark a job yellow, when a Maven build fails because of failing tests. If you don't want to have three status of your jobs, you can configure Jenkins so, that the jobs also mark red independent why a Maven build fails.


1 Answers

It's some time ago that I used hudson/jenkins but you should have a look at the Jenkins Glossary

Unstable build: A build is unstable if it was built successfully and one or more publishers report it unstable. For example if the JUnit publisher is configured and a test fails then the build will be marked unstable.

Publisher: A publisher is part of the build process other than compilation, for example JUnit test runs. A publisher may report stable or unstable result depending on the result of its processing. For example, if a JUnit test fails, then the whole JUnit publisher may report unstable.

So I suppose you have some other build parts (apart from JUnit) that report an unstable result. Have a look at the whole build process log.

like image 70
FrVaBe Avatar answered Oct 15 '22 14:10

FrVaBe