mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-03-24 17:31:14 +00:00
Inline a call to _compute_groups
The should_upgrade_srcarch method only needs _compute_groups for the purpose of computing smooth update candidates. In the concrete case, it is rather simple to inline that part directly (and fold away irrelevant code). This also enables us to rewrite _compute_groups to accept an migration item as all remaining callers simply unfold the migration item into the arguments required by _compute_groups. This change will come in a future commit. Signed-off-by: Niels Thykier <niels@thykier.net>
This commit is contained in:
parent
82ff8010e2
commit
e0c19b3adb
14
britney.py
14
britney.py
@ -980,10 +980,16 @@ class Britney(object):
|
||||
if not same_source or is_primary_source:
|
||||
smoothbins = set()
|
||||
if is_primary_source:
|
||||
_, _, smoothbins = self._compute_groups(src,
|
||||
primary_source_suite,
|
||||
arch,
|
||||
False)
|
||||
binaries_t = target_suite.binaries
|
||||
possible_smooth_updates = [p for p in source_u.binaries if p.architecture == arch]
|
||||
smoothbins = find_smooth_updateable_binaries(possible_smooth_updates,
|
||||
source_suite.sources[src],
|
||||
self.pkg_universe,
|
||||
target_suite,
|
||||
binaries_t,
|
||||
source_suite.binaries,
|
||||
frozenset(),
|
||||
self.options.smooth_updates)
|
||||
|
||||
# for every binary package produced by this source in testing for this architecture
|
||||
for pkg_id in sorted(x for x in source_t.binaries if x.architecture == arch):
|
||||
|
Loading…
x
Reference in New Issue
Block a user