Skip to content

Bug 1465588 - Remove unused Perfherder dashboard code#4211

Merged
sarah-clements merged 2 commits intomozilla:masterfrom
sarah-clements:remove-perf-dashboard
Nov 2, 2018
Merged

Bug 1465588 - Remove unused Perfherder dashboard code#4211
sarah-clements merged 2 commits intomozilla:masterfrom
sarah-clements:remove-perf-dashboard

Conversation

@sarah-clements
Copy link
Copy Markdown
Contributor

No description provided.

@sarah-clements sarah-clements requested review from camd and wlach October 30, 2018 22:17
Copy link
Copy Markdown
Contributor

@edmorley edmorley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yey for deleting dead code! :-D

import chunk from 'lodash/chunk';

import perf from '../../perf';
import { thDefaultRepo, phBlockers, phTimeRanges } from '../../../helpers/constants';
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The phBlockers constant is now unused so can be removed too

test-list="testList"
compare-results="compareResults"
filter-options="filterOptions"
release-blocker-criteria="1">
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe release-blocker-criteria corresponds to the releaseBlockerCriteria references in some of the remaining files (I hate Angular's automatic naming conversion) - which means they are now unused after this template is deleted. As such I think anything to do with "blockers" (eg releaseBlockerCriteria, showOnlyBlockers, isBlocker) can now be deleted from compare.js, the compare templates and a few other places.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This review comment was not addressed?

Copy link
Copy Markdown
Contributor Author

@sarah-clements sarah-clements Nov 2, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed below in the comment about newTitle and baseTitle :)

Edit: sorry, misunderstood your comment. Will look into it again and add this to a follow up pr.

<div ng-if="!dataLoading && !revisionNotFound">
<ph-compare-table
base-title={{baseTitle}}
new-title={{variantTitle}}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similarly, I believe all newTitle and baseTitle references can now also be removed, since the standard compare views don't use them.

Copy link
Copy Markdown
Contributor Author

@sarah-clements sarah-clements Nov 2, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems they're used in the trendtable.html and comparetable.html partials - either of which the phCompareTable component uses so leaving in for now (same applies to the blockers).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The baseTitle and newTitle variables allowed for overriding of the headings on those pages, however nothing overrides them any more, so they are always at default values. As such the default values can be moved from here:

if (!ctrl.baseTitle) {
ctrl.baseTitle = 'Base';
}
if (!ctrl.newTitle) {
ctrl.newTitle = 'New';
}

...to the templates, and then baseTitle and newTitle removed.

Copy link
Copy Markdown
Contributor Author

@sarah-clements sarah-clements Nov 2, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see - thanks for clarifying.

Copy link
Copy Markdown
Contributor

@wlach wlach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm assuming everything still works! Ed's suggestions look right to me.

Copy link
Copy Markdown
Collaborator

@camd camd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fantastic!

@sarah-clements sarah-clements merged commit debac0c into mozilla:master Nov 2, 2018
@sarah-clements sarah-clements deleted the remove-perf-dashboard branch November 2, 2018 01:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants