mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-03-12 20:01:08 +00:00
britney.py: Avoid creating empty lists for provides
Signed-off-by: Niels Thykier <niels@thykier.net>
This commit is contained in:
parent
203466bb51
commit
3ff01b5ec9
@ -965,7 +965,7 @@ class Britney(object):
|
||||
# Utility methods for package analysis
|
||||
# ------------------------------------
|
||||
|
||||
def get_dependency_solvers(self, block, packages_s_a):
|
||||
def get_dependency_solvers(self, block, packages_s_a, empty_set=frozenset()):
|
||||
"""Find the packages which satisfy a dependency block
|
||||
|
||||
This method returns the list of packages which satisfy a dependency
|
||||
@ -996,7 +996,7 @@ class Britney(object):
|
||||
packages.append(name)
|
||||
|
||||
# look for the package in the virtual packages list and loop on them
|
||||
for prov, prov_version in provides_s_a.get(name, []):
|
||||
for prov, prov_version in provides_s_a.get(name, empty_set):
|
||||
if prov not in binaries_s_a:
|
||||
continue
|
||||
# A provides only satisfies:
|
||||
|
Loading…
x
Reference in New Issue
Block a user