mirror of
https://gerrit.googlesource.com/git-repo
synced 2024-12-21 07:16:21 +00:00
Degrade: Fix smart sync/smart tag
This was broken inb2bd91c
, which updated the manifest after it had been overridden, which made it fall back to the original file (and not the one from the manifest server). This builds on0766900
and overrides the manifest by the one downloaded from the manifest server completely. Change-Id: Ic3972390a68919b614616631d99c9e7a63c0e0db
This commit is contained in:
parent
c2791e85f3
commit
53a6c5d93a
@ -526,6 +526,7 @@ later is required to fix a server side protocol bug.
|
|||||||
(username, password),
|
(username, password),
|
||||||
1)
|
1)
|
||||||
|
|
||||||
|
manifest_name = opt.manifest_name
|
||||||
try:
|
try:
|
||||||
server = xmlrpc.client.Server(manifest_server)
|
server = xmlrpc.client.Server(manifest_server)
|
||||||
if opt.smart_sync:
|
if opt.smart_sync:
|
||||||
@ -560,7 +561,7 @@ later is required to fix a server side protocol bug.
|
|||||||
print('error: cannot write manifest to %s' % manifest_path,
|
print('error: cannot write manifest to %s' % manifest_path,
|
||||||
file=sys.stderr)
|
file=sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
self.manifest.Override(manifest_name)
|
self._ReloadManifest(manifest_name)
|
||||||
else:
|
else:
|
||||||
print('error: %s' % manifest_str, file=sys.stderr)
|
print('error: %s' % manifest_str, file=sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
@ -593,7 +594,7 @@ later is required to fix a server side protocol bug.
|
|||||||
mp.Sync_LocalHalf(syncbuf)
|
mp.Sync_LocalHalf(syncbuf)
|
||||||
if not syncbuf.Finish():
|
if not syncbuf.Finish():
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
self._ReloadManifest(opt.manifest_name)
|
self._ReloadManifest(manifest_name)
|
||||||
if opt.jobs is None:
|
if opt.jobs is None:
|
||||||
self.jobs = self.manifest.default.sync_j
|
self.jobs = self.manifest.default.sync_j
|
||||||
all_projects = self.GetProjects(args,
|
all_projects = self.GetProjects(args,
|
||||||
@ -618,7 +619,7 @@ later is required to fix a server side protocol bug.
|
|||||||
# Iteratively fetch missing and/or nested unregistered submodules
|
# Iteratively fetch missing and/or nested unregistered submodules
|
||||||
previously_missing_set = set()
|
previously_missing_set = set()
|
||||||
while True:
|
while True:
|
||||||
self._ReloadManifest(opt.manifest_name)
|
self._ReloadManifest(manifest_name)
|
||||||
all_projects = self.GetProjects(args,
|
all_projects = self.GetProjects(args,
|
||||||
missing_ok=True,
|
missing_ok=True,
|
||||||
submodules_ok=opt.fetch_submodules)
|
submodules_ok=opt.fetch_submodules)
|
||||||
|
Loading…
Reference in New Issue
Block a user