Skip to content

Conversation

@DanielRyanSmith
Copy link
Contributor

@DanielRyanSmith DanielRyanSmith commented Aug 26, 2024

This change pulls mobile results data from the interop-results repo and uses it to display a new mobile results view on the Interop dashboard. The mobile results view can only be seen by toggling a flag in /flags.

Screen.Recording.2024-10-15.at.4.38.33.PM.mov

@DanielRyanSmith
Copy link
Contributor Author

It looks like the linter is failing due to an issue unrelated to this change.

api/query/cache/index/index.go:210:18: G115: integer overflow conversion uint64 -> int (gosec)
		shardIdx := int(t.testID % numShardsU64)
		               ^
api/query/cache/backfill/backfill.go:120:14: G115: integer overflow conversion uint64 -> int (gosec)
	limit := int(maxBytes/bytesPerRun) / len(shared.GetDefaultProducts())

securego/gosec#1149

@KyleJu
Copy link
Collaborator

KyleJu commented Aug 26, 2024

It looks like the linter is failing due to an issue unrelated to this change.

api/query/cache/index/index.go:210:18: G115: integer overflow conversion uint64 -> int (gosec)
		shardIdx := int(t.testID % numShardsU64)
		               ^
api/query/cache/backfill/backfill.go:120:14: G115: integer overflow conversion uint64 -> int (gosec)
	limit := int(maxBytes/bytesPerRun) / len(shared.GetDefaultProducts())

securego/gosec#1149

I will get to it shortly

@KyleJu
Copy link
Collaborator

KyleJu commented Aug 26, 2024

It looks like the linter is failing due to an issue unrelated to this change.

api/query/cache/index/index.go:210:18: G115: integer overflow conversion uint64 -> int (gosec)
		shardIdx := int(t.testID % numShardsU64)
		               ^
api/query/cache/backfill/backfill.go:120:14: G115: integer overflow conversion uint64 -> int (gosec)
	limit := int(maxBytes/bytesPerRun) / len(shared.GetDefaultProducts())

securego/gosec#1149

I will get to it shortly

Sent out #3968

@DanielRyanSmith DanielRyanSmith force-pushed the 2024-08-25_mobile-results-view branch from c07b579 to 7523fdf Compare August 27, 2024 21:04
@DanielRyanSmith
Copy link
Contributor Author

View the staging deployment here: https://2024-08-25-mobile-resu-dot-wptdashboard-staging.uk.r.appspot.com/interop-2024?mobileView

It might be worth changing this view in some way to be even more explicit that these are mobile results and experimental results.

@jgraham
Copy link
Contributor

jgraham commented Sep 10, 2024

I don't have detailed code-level feedback, but:

  • In general I approve the idea of landing something like this in some hidden way (query parameter, flag, etc.)
  • Even so, I think the page needs explicit text explaining that the mobile work remains a WIP and the scores may not reflect the real level of support for a given feature (don't want people to say "look how the mobile web sucks; browsers are X% worse on interop on mobile" if it's just test infra problems)

@past past closed this Sep 17, 2024
@past past reopened this Sep 17, 2024
@DanielRyanSmith
Copy link
Contributor Author

Some odd logic has been added in a commit that can be reverted later:

9068283

Once we have Safari results to populate the page

Copy link
Collaborator

@KyleJu KyleJu left a comment

Choose a reason for hiding this comment

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

LGTM with some minor comments

</paper-item>
<paper-item>
<paper-checkbox checked="{{showMobileScoresView}}">
Allow mobile results view on Interop dashboard
Copy link
Collaborator

@KyleJu KyleJu Oct 17, 2024

Choose a reason for hiding this comment

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

Enable or Show mobile results view on Interop dashboard to make the wording consistent?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I like it better. Changed!

}

q := r.URL.Query()
isMobileView, err := shared.ParseBooleanParam(q, "mobileView")
Copy link
Collaborator

Choose a reason for hiding this comment

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

It is recommended to use hyphens to separate words [1]. It is also consistent with API params here [2]

[1] https://developers.google.com/search/docs/crawling-indexing/url-structure
[2] https://developers.google.com/search/docs/crawling-indexing/url-structure

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good call - I'll change to use that syntax

</interop-summary>
</div>
<div class="grid-item grid-item-description">
<p>Interop [[year]] is a cross-browser effort to improve the interoperability of the web —
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
<p>Interop [[year]] is a cross-browser effort to improve the interoperability of the web
<p>Interop [[year]] is a cross-browser effort to improve the interoperability of the web -

Is this a hyphen? It looks really long

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 an em dash and was chosen to use by the team that wrote up this dashboard description

Copy link
Collaborator

Choose a reason for hiding this comment

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

Aha thanks!


let testScore = 0.0;
// Mobile csv does not have an Interop version column to account for.
let versionOffset = (this.isMobileScoresView && browserName === 'Interop') ? 0 : 1;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
let versionOffset = (this.isMobileScoresView && browserName === 'Interop') ? 0 : 1;
const versionOffset = (this.isMobileScoresView && browserName === 'Interop') ? 0 : 1;

_, isValidMobileYear := validMobileYears[year];
if isMobileView != nil && !isValidMobileYear {
year = defaultRedirectYear
needsRedirect = true
Copy link
Collaborator

Choose a reason for hiding this comment

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

minor detail: should it redirect to interop-2024? or interop-2024?mobile-view?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Currently, it maintains all query parameters, so e.g. /interop-2023?mobile-view will redirect to /interop-2024?mobile-view

Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't think that is the case testing on the staging deployment - https://2024-08-25-mobile-resu-dot-wptdashboard-staging.uk.r.appspot.com/interop-2023?mobile-view

Copy link
Collaborator

Choose a reason for hiding this comment

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

nm it worked! The staging deployment was not up-to-date, https://2024-08-25-mobile-resu-dot-wptdashboard-staging.uk.r.appspot.com/interop-2023?mobile-view. Thanks!

@DanielRyanSmith DanielRyanSmith merged commit aa11f43 into main Oct 21, 2024
12 checks passed
@DanielRyanSmith DanielRyanSmith deleted the 2024-08-25_mobile-results-view branch October 21, 2024 18:25
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.

5 participants