Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Checks: Plumb channel and improve robustness of diff urls #889

Merged
merged 10 commits into from
Dec 12, 2018

Conversation

lukebjerring
Copy link
Contributor

Description

See web-platform-tests/wpt#14465

This avoids version strings in a couple of cases.

@lukebjerring lukebjerring requested a review from Hexcles December 11, 2018 16:39
@wpt-pr-bot
Copy link

Staging instance deployed by Travis CI!
Running at https://diff-url-dot-wptdashboard-staging.appspot.com

@wpt-pr-bot
Copy link

Staging instance deployed by Travis CI!
Running at https://diff-url-dot-announcer-dot-wptdashboard-staging.appspot.com

Copy link
Member

@Hexcles Hexcles left a comment

Choose a reason for hiding this comment

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

So looks like this change would lose the product-specific labels. How do we differentiate stable & experimental Chrome then?

@lukebjerring
Copy link
Contributor Author

Reverted to keep including the labels, and explicitly clear the SHA instead.

shared/run_diff.go Outdated Show resolved Hide resolved
filter.Products = make(ProductSpecs, 2)
filter.Products[0].BrowserName = before.BrowserName
filter.Products[0].Revision = before.Revision
filter.Products[0].Labels = mapset.NewSet(before.Channel())
Copy link
Member

Choose a reason for hiding this comment

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

What about including all the labels?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sigh. Let's land #906 and then it doesn't matter at all.

@lukebjerring lukebjerring changed the title Checks: Improve robustness of diff urls Checks: Plumb channel and improve robustness of diff urls Dec 12, 2018
shared/models.go Outdated
case StableLabel,
ExperimentalLabel,
DevLabel,
BetaLabel:
Copy link
Member

Choose a reason for hiding this comment

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

This is a bit problematic: you're mixing the wpt.fyi "channels" with each browser's own channels. e.g. A Chrome run can have both "experimental" and "dev" labels: the latter is the browser channel extracted from the report while the former is the wpt.fyi channels inferred from the browser channel by the processor. This loop will nondeterministically return "dev" or "experimental" in this example.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah.. ok . Fixed.
A) #538 needs to be concluded
B) the query builders are wrong for a different, similar reason.

api/checks/update.go Show resolved Hide resolved
api/receiver/create_run.go Outdated Show resolved Hide resolved
shared/params.go Outdated Show resolved Hide resolved
@@ -172,8 +172,12 @@ func getDiffSummary(aeAPI shared.AppEngineAPI, diffAPI shared.DiffAPI, baseRun,
checkState := summaries.CheckState{
TestRun: &headRun,
Product: shared.ProductSpec{
ProductAtRevision: headRun.ProductAtRevision,
Labels: labels,
// [browser]@[sha] is plenty specific, and avoids bad version strings.
Copy link
Member

Choose a reason for hiding this comment

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

This is probably not specific enough in some cases.

Example: when headRun is a PR run, we would only pass browser[channel]@revision to GetMasterDiffURL, which will match to both pr_base and pr_head runs, and the users would always expect the pr_head run.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is deliberately the case. This only needs to identify any runs precisely enough for a given check; i.e. the CheckState's product is specific enough to identify chrome[experimental], and what the means as a check depends on what's been run (e.g. master vs an earlier master, pr_base vs pr_head, etc.)

As for below, let's rejig the API to take a run to diff against master, and then we can be less ambiguous :)

Copy link
Member

@Hexcles Hexcles left a comment

Choose a reason for hiding this comment

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

LGTM! Woohoo!

@lukebjerring
Copy link
Contributor Author

lukebjerring commented Dec 12, 2018

Double-checking behaviour @ https://github.com/lukebjerring/wpt/pull/8/checks?sha=6d14f4b50f4e9121bd55504a6cc33b471569eb2d (checks staging instance)

@lukebjerring lukebjerring merged commit c5ee41e into master Dec 12, 2018
@lukebjerring lukebjerring deleted the diff-url branch December 12, 2018 23:36
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.

3 participants