| Index: dashboard/dashboard/file_bug.py
|
| diff --git a/dashboard/dashboard/file_bug.py b/dashboard/dashboard/file_bug.py
|
| index 3bca816800b837309b6bc4d0bd216bf4212b2ae6..cc30ad9641c1c5ba24b94cff0df55cbe091d29df 100644
|
| --- a/dashboard/dashboard/file_bug.py
|
| +++ b/dashboard/dashboard/file_bug.py
|
| @@ -232,24 +232,26 @@ def _MilestoneLabel(alerts):
|
| Chromium milestones, do not label them (see
|
| https://github.com/catapult-project/catapult/issues/2906).
|
| """
|
| - revisions = [a.start_revision for a in alerts if hasattr(a, 'start_revision')]
|
| + revisions = [a.end_revision for a in alerts if hasattr(a, 'end_revision')]
|
| if not revisions:
|
| return None
|
| - start_revision = min(revisions)
|
| -
|
| + end_revision = min(revisions)
|
| for a in alerts:
|
| - if a.start_revision == start_revision:
|
| - master = utils.TestPath(a.GetTestMetadataKey()).split('/')[0]
|
| - if master != 'ChromiumPerf' and master != 'ChromiumPerfFyi':
|
| + if a.end_revision == end_revision:
|
| + row_key = utils.GetRowKey(a.test, a.end_revision)
|
| + row = row_key.get()
|
| + if hasattr(row, 'r_commit_pos'):
|
| + end_revision = row.r_commit_pos
|
| + else:
|
| return None
|
| break
|
| try:
|
| - milestone = _GetMilestoneForRevision(start_revision)
|
| + milestone = _GetMilestoneForRevision(end_revision)
|
| except KeyError:
|
| logging.error('List of versions not in the expected format')
|
| if not milestone:
|
| return None
|
| - logging.info('Matched rev %s to milestone %s.', start_revision, milestone)
|
| + logging.info('Matched rev %s to milestone %s.', end_revision, milestone)
|
| return 'M-%d' % milestone
|
|
|
|
|
| @@ -260,7 +262,7 @@ def _GetMilestoneForRevision(revision):
|
| by a suspected regression. We do this by locating in the list of current
|
| versions, regardless of platform and channel, all the version strings (e.g.
|
| 36.0.1234.56) that match revisions (commit positions) later than the earliest
|
| - possible start_revision of the suspected regression; we then parse out the
|
| + possible end_revision of the suspected regression; we then parse out the
|
| first numeric part of such strings, assume it to be the corresponding
|
| milestone, and return the lowest one in the set.
|
|
|
|
|