Skip to content

Commit

Permalink
Remove obsolete 'experimentalAlignedExceptEdge' admin flag
Browse files Browse the repository at this point in the history
This flag was used to fetch edge runs back when they were not tagged
with the experimental label. It is no longer useful, and is also
misleading (the name implies it might remove Edge from the default
query, which it does not do). As such, remove it.

This also makes util/populate_dev_data.go closer to what is shipped on
wpt.fyi
  • Loading branch information
stephenmcgruer committed Mar 4, 2021
1 parent 31146ca commit 3a0f20e
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 32 deletions.
17 changes: 0 additions & 17 deletions shared/test_run_filter.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,23 +119,6 @@ func (filter TestRunFilter) OrExperimentalRuns() TestRunFilter {
return filter
}

// OrAlignedExperimentalRunsExceptEdge returns the current filter, or, if it is a default
// query, returns a query for the latest experimental runs.
func (filter TestRunFilter) OrAlignedExperimentalRunsExceptEdge() TestRunFilter {
if !filter.IsDefaultQuery() {
return filter
}
aligned := true
filter.Aligned = &aligned
filter.Products = GetDefaultProducts()
for i := range filter.Products {
if filter.Products[i].BrowserName != "edge" {
filter.Products[i].Labels = mapset.NewSetWith("experimental")
}
}
return filter
}

// MasterOnly returns the current filter, ensuring it has with the master-only
// restriction (a label of "master").
func (filter TestRunFilter) MasterOnly() TestRunFilter {
Expand Down
2 changes: 1 addition & 1 deletion util/populate_dev_data.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ func main() {
addFlag(store, "diffFilter", enabledFlag)
addFlag(store, "diffFromAPI", enabledFlag)
addFlag(store, "experimentalByDefault", enabledFlag)
addFlag(store, "experimentalAlignedExceptEdge", enabledFlag)
addFlag(store, "experimentalAligned", enabledFlag)
addFlag(store, "structuredQueries", enabledFlag)
addFlag(store, "diffRenames", enabledFlag)
addFlag(store, "paginationTokens", enabledFlag)
Expand Down
6 changes: 0 additions & 6 deletions webapp/components/wpt-flags.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ Object.defineProperty(wpt, 'ClientSideFeatures', {
'displayMetadata',
'experimentalByDefault',
'experimentalAligned',
'experimentalAlignedExceptEdge',
'fetchManifestForTestList',
'githubCommitLinks',
'githubLogin',
Expand Down Expand Up @@ -304,11 +303,6 @@ class WPTEnvironmentFlagsEditor extends FlagsEditorClass(/*environmentFlags*/ tr
Align the default experimental runs
</paper-checkbox>
</paper-item>
<paper-item sub-item>
<paper-checkbox checked="{{experimentalAlignedExceptEdge}}">
All experimental, except edge[stable], and aligned
</paper-checkbox>
</paper-item>
<paper-item>
<paper-checkbox checked="{{paginationTokens}}">
Return "wpt-next-page" pagination token HTTP header in /api/runs
Expand Down
12 changes: 4 additions & 8 deletions webapp/test_results_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,14 +105,10 @@ func populateHomepageData(r *http.Request) (data homepageData, err error) {
} else {
if pr == nil && testRunFilter.IsDefaultQuery() {
if aeAPI.IsFeatureEnabled("experimentalByDefault") {
if aeAPI.IsFeatureEnabled("experimentalAlignedExceptEdge") {
testRunFilter = testRunFilter.OrAlignedExperimentalRunsExceptEdge()
} else {
testRunFilter = testRunFilter.OrExperimentalRuns()
if aeAPI.IsFeatureEnabled("experimentalAligned") {
aligned := true
testRunFilter.Aligned = &aligned
}
testRunFilter = testRunFilter.OrExperimentalRuns()
if aeAPI.IsFeatureEnabled("experimentalAligned") || true {
aligned := true
testRunFilter.Aligned = &aligned
}
} else {
testRunFilter = testRunFilter.OrAlignedStableRuns()
Expand Down

0 comments on commit 3a0f20e

Please sign in to comment.