[Buildbot-devel] Retrieving build results

Brian Warner warner-buildbot at lothar.com
Tue Nov 29 09:12:03 UTC 2005

> However, that's not really the point.  I was more arguing that there
> should be a nice way to determine the attributes of the build without
> having to use 'svn info' - it would be nice if the current branch,
> VC revision and whether it is a 'try' build could be provided to the
> build step somehow.  Maybe the changes and the try patch too?

Hmm. Yes, it would be nice to have these accessible from within the build
process. I've also been thinking about some way to communicate other
variables to the build process, specifically a set of test cases to run, for
'try' builds. I'd like to be able to say:

 buildbot try buildbot.test.test_vc

and have all the metabuildbot slaves run the "test_vc" test cases. To do this
requires a number of changes, culminating in an additional argument being
passed to their Trial steps. I'm not sure what the first changes should be..
possibly adding a dictionary of arguments to the Build, or adding something
wacky to the SourceStamp. I haven't thought of something that seems clean

Either this extra information (whether arguments like which tests to run, or
build information like a revision and branch name) could be available to the
BuildSteps and then they could be responsible for passing them into the
remote commands, or it could be passed to *all* commands through environment
variables. I'm inclined to go with the former, under the maxim that "explicit
is better than implicit", but to make that useable I'd want to first make it
easier to override the actual shell command being executed. This probably
involves just a little refactoring of step.ShellCommand, but my concern is on
how to make it easy to set up from within the config file. Something like

def makeShellCommand(args):
    return ["trial", "-v", args.get("testcases", "buildbot.test")]
f = factory.BuildFactory([s(step.SVN, stuff=foo),
                          s(step.Compile, stuff=foo),
                          s(step.Trial, setup=makeShellCommand, stuff=foo)])

anyway, that's what I vaguely have in mind. Let me know what you think.


More information about the devel mailing list