pkglistgen: log unsorted locale packages
For some yet to be determined reason, the namespaceprovider does not pick up package that just provide eg. locale(ja). So find and and log them (boo#1092055)
This commit is contained in:
parent
0429ee2f69
commit
5311708270
@ -527,6 +527,7 @@ class PkgListGen(ToolBase.ToolBase):
|
|||||||
|
|
||||||
def _check_supplements(self):
|
def _check_supplements(self):
|
||||||
tocheck = set()
|
tocheck = set()
|
||||||
|
tocheck_locales = set()
|
||||||
for arch in self.architectures:
|
for arch in self.architectures:
|
||||||
pool = self._prepare_pool(arch)
|
pool = self._prepare_pool(arch)
|
||||||
sel = pool.Selection()
|
sel = pool.Selection()
|
||||||
@ -539,6 +540,11 @@ class PkgListGen(ToolBase.ToolBase):
|
|||||||
if d.startswith('namespace:modalias') or d.startswith('namespace:filesystem'):
|
if d.startswith('namespace:modalias') or d.startswith('namespace:filesystem'):
|
||||||
tocheck.add(s.name)
|
tocheck.add(s.name)
|
||||||
|
|
||||||
|
for l in self.locales:
|
||||||
|
i = pool.str2id('locale({})'.format(l))
|
||||||
|
for s in pool.whatprovides(i):
|
||||||
|
tocheck_locales.add(s.name)
|
||||||
|
|
||||||
all_grouped = set()
|
all_grouped = set()
|
||||||
for g in self.groups.values():
|
for g in self.groups.values():
|
||||||
if g.solved:
|
if g.solved:
|
||||||
@ -549,6 +555,9 @@ class PkgListGen(ToolBase.ToolBase):
|
|||||||
for p in tocheck - all_grouped:
|
for p in tocheck - all_grouped:
|
||||||
logger.warn('package %s has supplements but is not grouped', p)
|
logger.warn('package %s has supplements but is not grouped', p)
|
||||||
|
|
||||||
|
for p in tocheck_locales - all_grouped:
|
||||||
|
logger.warn('package %s provides supported locale but is not grouped', p)
|
||||||
|
|
||||||
def _prepare_pool(self, arch):
|
def _prepare_pool(self, arch):
|
||||||
pool = solv.Pool()
|
pool = solv.Pool()
|
||||||
pool.setarch(arch)
|
pool.setarch(arch)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user