Build Result Codes

Buildbot represents the status of a step, build, or buildset using a set of numeric constants. From Python, these constants are available in the module buildbot.status.results, but the values also appear in the database and in external tools, so the values are fixed.

buildbot.status.results.SUCCESS

Value: 0; color: green; a successful run.

buildbot.status.results.WARNINGS

Value: 1; color: orange; a successful run, with some warnings.

buildbot.status.results.FAILURE

Value: 2; color: red; a failed run, due to problems in the build itself, as opposed to a Buildbot misconfiguration or bug.

buildbot.status.results.SKIPPED

Value: 3; color: white; a run that was skipped -- usually a step skipped by doStepIf (see Common Parameters)

buildbot.status.results.EXCEPTION

Value: 4; color: purple; a run that failed due to a problem in Buildbot itself.

buildbot.status.results.RETRY

Value: 4; color: purple; a run that should be retried, usually due to a slave disconnection.

buildbot.status.results.CANCELLED

Value: 5; color: pink; a run that was cancelled by the user.

buildbot.status.results.Results

A dictionary mapping result codes to their lowercase names.

buildbot.status.results.worst_status(a, b)

This function takes two status values, and returns the "worst" status of the two. This is used to aggregate step statuses into build statuses, and build statuses into buildset statuses.

computeResultAndTermination(obj, result, previousResult):
Parameters:
  • obj -- an object with the attributes of ResultComputingConfigMixin
  • result -- the new result
  • previousResult -- the previous aggregated result

Building on worst_status, this function determines what the aggreagated overall status is, as well as whether the attempt should be terminated, based on the configuration in obj.

class buildbot.status.results.ResultComputingConfigMixin

This simple mixin is intended to help implement classes that will use computeResultAndTermination. The class has, as class attributes, the result computing configuration parameters with default values:

haltOnFailure
flunkOnWarnings
flunkOnFailure
warnOnWarnings
warnOnFailure

The names of these attributes are available in the following attribute:

resultConfig