pyjen.build module

Primitives for interacting with Jenkins builds

class pyjen.build.Build(data_io_controller)[source]

Bases: object

Class that encapsulates information about a single build / run of a Job

Builds are executions of jobs and thus instances of this class are typically generated from the Job class.

See also

Job

Parameters:data_io_controller (DataRequester) – class capable of handling common HTTP IO requests sent by this object to the Jenkins REST API
artifact_urls[source]

Gets a list of URLs which can be used to download the published build artifacts for this build

Return type:list of str
changeset[source]

Gets the list of SCM changes associated with this build

Returns:0 or more SCM changesets associated with / included in this build. If no changesets are found, returns None
Return type:Changeset
console_output[source]

Gets the raw console output for this build as plain text

Returns:Raw console output from this build, in plain text format
Return type:str
description[source]

Gets the descriptive test associated with this build

Return type:str
id[source]

Gets the unique identifier associated with this build

Return type:str
is_building[source]

Checks to see whether this build is currently executing

Returns:True if the build is executing otherwise False
Return type:bool
number[source]

Gets the sequence number of this build

Returns:sequentially assigned integer value associated with this build
Return type:int
result[source]

Gets the final status of this build

Returns:the status of this build. Typically “SUCCESS” or “FAILURE” but may also be “UNSTABLE”
Return type:func:str
start_time[source]

Gets the time stamp of when this build was started

Returns:the date and time at which this build was started
Return type:datetime.datetime
status[source]

Gets the status of the build

Returns:Result state of the associated job upon completion of this build. Typically one of the following:
  • “SUCCESS”
  • “UNSTABLE”
  • “FAILED”
Return type:str