mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-05-28 19:01:35 +00:00
Ensure get_auto_hinter_hints does not choke on cruft items
Signed-off-by: Niels Thykier <niels@thykier.net>
This commit is contained in:
parent
16f823dd91
commit
32ebe9d4e0
@ -1967,7 +1967,8 @@ class Britney(object):
|
|||||||
|
|
||||||
# consider only excuses which are valid candidates and still relevant.
|
# consider only excuses which are valid candidates and still relevant.
|
||||||
valid_excuses = frozenset(y.uvname for y in upgrade_me
|
valid_excuses = frozenset(y.uvname for y in upgrade_me
|
||||||
if y not in sources_t or sources_t[y].version != excuses[y].ver[1])
|
if not y.is_cruft_removal and
|
||||||
|
(y not in sources_t or sources_t[y].version != excuses[y].ver[1]))
|
||||||
excuses_deps = {name: valid_excuses.intersection(excuse.get_deps())
|
excuses_deps = {name: valid_excuses.intersection(excuse.get_deps())
|
||||||
for name, excuse in excuses.items() if name in valid_excuses}
|
for name, excuse in excuses.items() if name in valid_excuses}
|
||||||
excuses_rdeps = defaultdict(set)
|
excuses_rdeps = defaultdict(set)
|
||||||
|
@ -19,12 +19,13 @@ from britney2 import SuiteClass
|
|||||||
|
|
||||||
class MigrationItem(object):
|
class MigrationItem(object):
|
||||||
|
|
||||||
def __init__(self, package=None, version=None, architecture=None, uvname=None, suite=None):
|
def __init__(self, package=None, version=None, architecture=None, uvname=None, suite=None, is_cruft_removal=False):
|
||||||
self._uvname = uvname
|
self._uvname = uvname
|
||||||
self._package = package
|
self._package = package
|
||||||
self._version = version
|
self._version = version
|
||||||
self._architecture = architecture
|
self._architecture = architecture
|
||||||
self._suite = suite
|
self._suite = suite
|
||||||
|
self._is_cruft_removal = is_cruft_removal
|
||||||
if version is not None:
|
if version is not None:
|
||||||
self._name = "%s/%s" % (uvname, version)
|
self._name = "%s/%s" % (uvname, version)
|
||||||
else:
|
else:
|
||||||
@ -80,6 +81,10 @@ class MigrationItem(object):
|
|||||||
def uvname(self):
|
def uvname(self):
|
||||||
return self._uvname
|
return self._uvname
|
||||||
|
|
||||||
|
@property
|
||||||
|
def is_cruft_removal(self):
|
||||||
|
return self._is_cruft_removal
|
||||||
|
|
||||||
|
|
||||||
class MigrationItemFactory(object):
|
class MigrationItemFactory(object):
|
||||||
|
|
||||||
@ -95,7 +100,8 @@ class MigrationItemFactory(object):
|
|||||||
version=pkg_id.version,
|
version=pkg_id.version,
|
||||||
architecture=pkg_id.architecture,
|
architecture=pkg_id.architecture,
|
||||||
uvname=uvname,
|
uvname=uvname,
|
||||||
suite=self._suites.target_suite
|
suite=self._suites.target_suite,
|
||||||
|
is_cruft_removal=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
Loading…
x
Reference in New Issue
Block a user