[Buildbot-devel] Still have problems with schedulers passing wrongbranches

Gavin gavin at 16degrees.com.au
Wed Aug 26 11:42:10 UTC 2009


I'm not sure using branch=None is helping matters.

Im also not sure of your exact svn setup. Considering your BaseURL
exception, perhaps you should try using that in all your factories.

Here is an example of what we use.

c['schedulers'].append(AnyBranchScheduler(name="on-rat-commit",
                         branches=["incubator/rat/main/trunk"],
                         treeStableTimer=2,
                         builderNames=["rat_trunk"]))

#builders

f2 = factory.BuildFactory()
f2.addStep(SVN(
    mode="clobber",
    baseURL="http://svn.apache.org/repos/asf/",
    defaultBranch="incubator/rat/main/trunk",
))

Note that if you go and browse http://svn.apache.org/repos/asf/ you will see
100+ projects there, I have one Buildbot master managing all of the projects
that want to use it and use a modified svn post-commit hook to send the
branch info to buildbot (via svn_buildbot.py), all other non-participating
branches are ignored. Probably straying off-topic there, but anyway, perhaps
using baseURL combined with branches/defaultBranch might put you on the
right track.

Gav...

> -----Original Message-----
> From: Bailey, Darragh [mailto:dbailey at hp.com]
> Sent: Tuesday, 25 August 2009 8:35 PM
> To: buildbot-devel list
> Subject: [Buildbot-devel] Still have problems with schedulers passing
> wrongbranches
> 
> 
> 
> Still running into a problem with a build triggered by another build using
> the wrong branch.
> 
> What I was running (shortened):
> buildA.addStep( SVN(baseURL=svnurl, defaultBranch="trunk",...) )
> buildB.addStep( SVN(baseURL=svnurl, defaultBranch="trunk",...) )
> buildC.addStep( SVN(baseURL=svnurl, defaultBranch="branches/branchC",...)
> )
> 
> BuildB.addStep(Trigger(schedulerNames("RunBuildA")))
> BuildC.addStep(Trigger(schedulerNames("RunBuildA")))
> 
> c['schedulers'].append(Triggerable(name="RunBuildA",...))
> c['schedulers'].append(Nightly(name="RunBuildB", branch=None, ...))
> c['schedulers'].append(Nightly(name="RunBuildC", branch=None, ...))
> 
> Which all worked fine.
> 
> But I wanted to switch buildC to work from a scheduler that triggered
> based on commits to the branch "branches/branchC".
> 
> So I changed the last Nightly scheduler to the following:
> c['schedulers'].append(Scheduler(name="RunBuildConCommit",
> branch="branches/branchC", ...)
> 
> Now I included the branch since I believed that is how the scheduler is
> told which branch to watch for changes, otherwise as I understand, it
> would take changes from any branch including trunk.
> 
> The problem appears to be, based on reviewing the properties that get
> passed to the triggered build, that as a result of setting the branch in
> the scheduler, it changes the branch used for the triggered build,
> "buildA", to be "branches/branchC" which is not what I want. I always want
> "buildA" to use trunk. Tweaking "buildA" SVN step to use
> "svnurl=svnurl+'trunk'" instead results in a exception whenever the
> builder receives a branch since it complains "assert not branch # we need
> baseURL= to use branches".
> 
> So what am I missing? Do I need to write a custom scheduler to handle
> this, or am I just overlooking something that is already available?
> 
> --
> Regards,
> Darragh Bailey
> 
> Systems Software Engineer
> Hewlett Packard Galway Ltd.
> 
> Postal Address:    Hewlett Packard Galway Limited, Ballybrit Business
> Park, Galway
> Registered Office: Hewlett Packard Galway Limited, 63-74 Sir John
> Rogerson's Quay Dublin 2
> Registered Number: 361933
> 
> 
> --------------------------------------------------------------------------
> ----
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-
> Day
> trial. Simplify your report design, integration and deployment - and focus
> on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> _______________________________________________
> Buildbot-devel mailing list
> Buildbot-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/buildbot-devel
> No virus found in this incoming message.
> Checked by AVG - www.avg.com
> Version: 8.5.408 / Virus Database: 270.13.64/2320 - Release Date: 08/22/09
> 18:04:00





More information about the devel mailing list