Fr4ncky / git-repo

Automatically exported from code.google.com/p/git-repo
Apache License 2.0
0 stars 0 forks source link

local_manifests/ not working (not finding the new xml file) #127

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I'm trying to use the new local_manifests feature, as suggested by the latest 
repo.

This is Ubuntu 12.04.

repo --version
repo version v1.12.0
       (from https://gerrit.googlesource.com/git-repo)
repo launcher version 1.19
       (from /[...]/home/jbq/bin/repo)
git version 1.7.7.3
Python 2.7.3 (default, Aug  1 2012, 05:14:39) 
[GCC 4.6.3]

What steps will reproduce the problem?
mkdir -p .repo/local_manifests
mv .repo/local_manifest.xml .repo/local_manifests/vendor.xml
repo sync

Traceback (most recent call last):
[...]
  File "/a/p/m/.repo/repo/subcmds/sync.py", line 152, in _Options
    self.jobs = self.manifest.default.sync_j
  File "/a/p/m/.repo/repo/manifest_xml.py", line 293, in default
    self._Load()
  File "/a/p/m/.repo/repo/manifest_xml.py", line 349, in _Load
    nodes.append(self._ParseManifestXml(local_file, self.repodir))
  File "/a/p/m/.repo/repo/manifest_xml.py", line 365, in _ParseManifestXml
    root = xml.dom.minidom.parse(path)
  File "/usr/lib/python2.7/xml/dom/minidom.py", line 1920, in parse
    return expatbuilder.parse(file)
  File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 922, in parse
    fp = open(file, 'rb')
IOError: [Errno 2] No such file or directory: 'vendor.xml'

Original issue reported on code.google.com by jbq@android.com on 4 Jan 2013 at 8:42

GoogleCodeExporter commented 9 years ago
I confirm it too.

Line 349 of manifest_xml.py

              nodes.append(self._ParseManifestXml(local_file, self.repodir))

should be replaced by

              local_path = os.path.join(local_dir, local_file)
              nodes.append(self._ParseManifestXml(local_path, self.repodir))

Original comment by j.ruesga...@gmail.com on 4 Jan 2013 at 8:55

GoogleCodeExporter commented 9 years ago
Here is a patch fixing it.

Original comment by cryptom...@gmail.com on 15 Jan 2013 at 3:07

Attachments:

GoogleCodeExporter commented 9 years ago
Fixed with:

https://gerrit-review.googlesource.com/#/c/40792/

Original comment by david.pu...@sonymobile.com on 1 Feb 2013 at 2:08