[Buildbot-devel] configuration help
seefeld at sympatico.ca
Fri Nov 25 00:06:15 UTC 2005
Brian Warner wrote:
>>It sounds as if I could somehow derive from PBChangeSource and then determine
>>the branch during a call to my (redefined) perspective_addChange method.
> Yeah, that would work. In that case you should probably assert that the
> changes you're receiving from svn_buildbot.py have no 'branch' key, to guard
> against running your derived BranchCalculatingPBChangeSource subclass in
> conjunction with some new svn_buildbot_which_calculates_branches.py sender.
Indeed. I would use that as a temporary hack only, until some 'official'
way to do the same exists.
>>(I think it would be nice to be able to just provide such a branch-detector
>>as a callable I can provide to PBChangeSource's constructor.)
> Yeah, I agree. I really want there to be a simple place where you put the
> filename->branch conversion function, and it would be easiest to put it
> somewhere in master.cfg . I'd like to change or get rid of the 'prefix='
> argument at the same time, since it's doing vaguely the same thing.
> I'm going to have to think about this part. Maybe there's a clean way to let
> either the sender (svn_buildbot.py) or the recipient (PBChangeSource)
> calculate the branch.
Ok, I'll think about it some more, too. May be I can send in a patch to
the PBChangeSource class that would take such a branch discriminator callable
in its constructor, and then applies it to each change, if no 'branch'
key is set ?
>>ah, I didn't know about the branches=None option (is it documented at all ?).
>>Indeed, I provided an explicit branch list, as suggested by the manual.
> It's in the docstring (try pydoc buildbot.scheduler.AnyBranchScheduler), but
> not in the manual. I just added a section to the manual giving brief
> descriptions of all available schedulers, and pointing the reader at the
> docstrings. I suppose I should copy the docstrings into the manual, but I'm a
> little afraid of version skew.. how to make sure I remember to update the
> manual when the source code and docstrings are updated. It'd be nice if
> texinfo could interpolate external files or something.
You may want to consider processing your code with something like happydoc
to generate a ref manual for all those gory details. That would complement
some high level design document (and tutorial) quite nicely.
More information about the devel