[Buildbot] #2574: GerritChangeSource extracts wrong branch name when using Gerrit 2.7

Buildbot trac trac at buildbot.net
Mon Jan 26 18:14:45 UTC 2015


#2574: GerritChangeSource extracts wrong branch name when using Gerrit 2.7
-----------------------------+-----------------------
Reporter:  dluntzer          |       Owner:
    Type:  defect            |      Status:  assigned
Priority:  patches-accepted  |   Milestone:  0.9.+
 Version:  0.8.8             |  Resolution:
Keywords:  gerrit            |
-----------------------------+-----------------------

Comment (by tardyp):

 This behavior is expected, and made on purpose, whatever version of gerrit
 I am aware of.

 The 'branch' option is used by buildbot in tree stable timers with
 anybranchscheduler in order wait for patch stabilization.
 The 'real' git branch includes the version of the patchset, so a new
 version of the same patch  would be considered as another branch for
 anybranchscheduler, and trigger another build.
 This is why we use <branch>/<patchnumber> as branch identifier in
 buildbot. Of course this branch wont work in git, this is why you have to
 use Gerrir() step instead of Git(), which takes the correct property to
 initialize the step.

 Here is example of integration of the gerrit story in buildbot_travis
 https://github.com/tardyp/buildbot_travis/blob/master/buildbot_travis/vcs/gerrit.py

 This version of buildbot_travis supports gerrit as backend with pre-commit
 and post-commit builders. I am currently validating all use cases, but it
 looks like working. Sorting out how to work with branches was indeed not
 obvious.

 I will be upstreaming my changes to GerritChangeSource, as they are not
 really specific to travis process.

--
Ticket URL: <http://trac.buildbot.net/ticket/2574#comment:7>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation


More information about the bugs mailing list