Page MenuHomePhabricator

Zuul merge will always fail for wikimedia/fundraising/crm
Closed, ResolvedPublic

Description

Author: mwalker

Description:
Zuul keeps telling us; with every patch; that it cannot merge into the repository.

Mark took a look at it a while back and inferred that it might have to do with the fact that we have two subrepos already created and so it's not seeing the need to initialize this repository; but he was uncomfortable with just initializing the repo by hand. An upstream bug was filed at https://bugs.launchpad.net/zuul/+bug/1235005

Here's a test patch to look at: https://gerrit.wikimedia.org/r/#/c/87457/


Version: wmf-deployment
Severity: minor

Details

Reference
bz55896

Event Timeline

bzimport raised the priority of this task from to High.Nov 22 2014, 2:16 AM
bzimport set Reference to bz55896.

Zuul fetch the repositories using their project names under
gallium.wikimedia.org:/srv/ssd/zuul/git

Hence we have:

wikimedia/fundraising/crm
wikimedia/fundraising/drupal
wikimedia/fundraising/civicrm

The crm one was empty, most probably because git clone refuse to process
on an existing directory. So I created it myself:

git remote add origin
ssh://jenkins-bot@ytterbium.wikimedia.org:29418/wikimedia/fundraising/crm
git fetch

Which is nice. But that crm repository has two directories civicrm
and drupal which are already cloned by Zuul to proceed changes made
against wikimedia/fundraising/{civicrm,drupal}.

So that is most probably going to be slightly conflicting since Zuul
attempt to reset the repository to be able to merge the received change
on the tip of the branch.

2013-10-18 20:16:01,155 DEBUG zuul.Repo: Resetting repository
/srv/ssd/zuul/git/wikimedia/fundraising/crm
2013-10-18 20:16:01,155 DEBUG zuul.Repo: Updating repository
/srv/ssd/zuul/git/wikimedia/fundraising/crm

2013-10-18 20:16:01,258 ERROR zuul.Merger: Unable to reset repo
<zuul.merger.Repo object at 0x7f2df0ab2290>
Traceback (most recent call last):

File

"/usr/local/lib/python2.7/dist-packages/zuul-aa106af-py2.7.egg/zuul/merger.py",
line 212, in mergeChanges

  repo.reset()
File

"/usr/local/lib/python2.7/dist-packages/zuul-aa106af-py2.7.egg/zuul/merger.py",
line 54, in reset

  self.repo.head.reference = origin.refs['HEAD']
File "/usr/lib/python2.7/dist-packages/git/util.py", line 621, in

getitem

raise IndexError( "No item found with id %r" % (self._prefix + index) )

IndexError: No item found with id 'origin/HEAD'

And indeed:

$ git rev-parse origin/HEAD
origin/HEAD
fatal: ambiguous argument 'origin/HEAD': unknown revision or path not in
the working tree.
Use '--' to separate paths from revisions
$

$ git remote set-head origin -a
origin/HEAD set to master
$

That fixed that.

$ git rev-parse origin/HEAD
6db93ec736b36131b76de3f240446ccd42cd9fb8
$

Play ground area is/was https://gerrit.wikimedia.org/r/#/c/87457/

That managed to get a phplint job to run :] So I guess it is fixed.