Only count live items for relative priority
Non-live items in a pipeline don't have node requests, so don't penalize long patch series by counting the non-live ancestors of changes when calculating relative_priority. Change-Id: I7ec63e2ea4403087dd43c3b15eb703a2fa5542a7
This commit is contained in:
parent
505c32e4b2
commit
101ec7c486
|
@ -87,7 +87,9 @@ class PipelineManager(object):
|
|||
|
||||
def getNodePriority(self, item):
|
||||
items = self.pipeline.getAllItems()
|
||||
items = [i for i in items if i.change.project == item.change.project]
|
||||
items = [i for i in items
|
||||
if i.change.project == item.change.project and
|
||||
i.live]
|
||||
for idx, val in enumerate(items):
|
||||
if item == val:
|
||||
return idx
|
||||
|
|
Loading…
Reference in New Issue