request_splitter: add strategy_do_non_bootstrapped().

Utilize in select command to fallback to none strategy and also excluded
packages that require bootstrapping.
This commit is contained in:
Jimmy Berry 2017-02-18 00:03:55 -06:00
parent 17147acb15
commit 27a6772dce
2 changed files with 7 additions and 0 deletions

View File

@ -371,6 +371,7 @@ def do_staging(self, subcmd, opts, *args):
# Merge any none strategies before final none strategy.
splitter.merge(strategy_none=True)
splitter.strategy_do('none')
splitter.strategy_do_non_bootstrapped('none')
proposal = splitter.proposal
if len(proposal) == 0:

View File

@ -298,6 +298,12 @@ class RequestSplitter(object):
self.split()
self.propose_assignment()
def strategy_do_non_bootstrapped(self, name, **kwargs):
self.strategy_set(name, **kwargs)
self.filter_add('./action/target[not(starts-with(@ring, "0"))]')
self.split()
self.propose_assignment()
def filter_grouped(self, groups):
for group in sorted(self.grouped.keys()):
if group not in groups: