mirror of
https://gerrit.googlesource.com/git-repo
synced 2026-05-30 06:29:52 +00:00
manifest_xml: prevent extend-project from inheriting local groups
When extending a project in a local manifest, the project inherits the `local:` group. This causes the superproject override logic (which omits projects with `local:` groups) to incorrectly exclude the project from the override manifest. This leads to "extend-project element specifies non-existent project" errors during sync reload. Fix this by stripping `local:` groups from extended projects, ensuring they remain visible to superproject overrides while still allowing other inherited groups to persist. Bug: 470374343 Change-Id: I1a057ebffebc11a19dc14dde7cc13b9f18cdd0a3 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/543222 Reviewed-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Reviewed-by: Mike Frysinger <vapier@google.com> Tested-by: Gavin Mak <gavinmak@google.com> Commit-Queue: Gavin Mak <gavinmak@google.com>
This commit is contained in:
@@ -1487,6 +1487,14 @@ https://gerrit.googlesource.com/git-repo/+/HEAD/docs/manifest-format.md
|
||||
continue
|
||||
if groups:
|
||||
p.groups |= groups
|
||||
# Drop local groups so we don't mistakenly omit this
|
||||
# project from the superproject override manifest.
|
||||
p.groups = {
|
||||
g
|
||||
for g in p.groups
|
||||
if not g.startswith(LOCAL_MANIFEST_GROUP_PREFIX)
|
||||
}
|
||||
|
||||
if revision:
|
||||
if base_revision:
|
||||
if p.revisionExpr != base_revision:
|
||||
|
||||
Reference in New Issue
Block a user