Page MenuHomePhabricator

Interface customization baseline instrumentation
Closed, ResolvedPublic5 Estimated Story Points

Description

Background

The WE2.1 KR states: Ensure a quality reading experience for all users by adapting the default experience for 15% of pageviews, based on the individual needs and constraints of the user. We would like to establish a baseline for this metric by looking at at the frequency of how the interface currently adapts

Acceptance criteria

QA

Note: https://grafana.wikimedia.org/d/000000566/overview?orgId=1 may be helpful

  • This will impact the live schema so make sure DesktopWebUIClickTracking volume is not impacted
  • This will impact the live schema so make sure MobileWebUIClickTracking volume is not impacted
  • All events should contain the new accessibility fields

QA Results - Beta

QA Results - Prod

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
Jdrewniak set the point value for this task to 5.Sep 12 2023, 4:42 PM

Change 958594 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@master] Add fields to web common

https://gerrit.wikimedia.org/r/958594

Change 960136 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[mediawiki/skins/Vector@master] Add client-side preference classes

https://gerrit.wikimedia.org/r/960136

Change 960141 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[schemas/event/secondary@master] Adds new web fragment

https://gerrit.wikimedia.org/r/960141

Change 958594 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@master] Adds fields webAccessibilitySettings js

https://gerrit.wikimedia.org/r/958594

Change 960141 merged by jenkins-bot:

[schemas/event/secondary@master] Adds new web fragment

https://gerrit.wikimedia.org/r/960141

Change 960136 merged by jenkins-bot:

[mediawiki/skins/Vector@master] Add new utility function for detecting pinned elements

https://gerrit.wikimedia.org/r/960136

Change 958594 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] Introduce Web Accessibility Features and Submodule

https://gerrit.wikimedia.org/r/958594

QA Instructions

  1. Validate the event tracking and data collection as outlined in the following tables.
  2. Test both logged-in and logged-out states.
  3. Mobile has additional new fields because it now shares a new fragment with desktop, so it will also have is_pinned, is_media_viewer_enabled, etc. This is expected behavior.

Minerva (Mobile)

DescriptionSchemaFieldsExpected ResultsLogged In Status
Number of pageviewsMobileWebUIActionsTrackingevent.action="init"On load, the init event should always fire.Check both logged in and logged out
Session IDMobileWebUIActionsTrackingevent.tokenToken field must always be includedCheck both logged in and logged out
Skin nameMobileWebUIActionsTrackingevent.skin='minerva'Skin field must always be includedCheck both logged in and logged out
Font sizeMobileWebUIActionsTrackingevent.fontFor now, should always return falseCheck both logged in and logged out

Vector 2022 (Desktop)

DescriptionSchemaFieldsExpected ResultsLogged In Status
Number of pageviewsdesktopwebuiactionstrackingevent.action="init"On load, the init event should always fire.Check both logged in and logged out
Session IDdesktopwebuiactionstrackingevent.tokenToken field must always be includedCheck both logged in and logged out
Skin namedesktopwebuiactionstrackingevent.skin='vector-2022'Skin field must always be includedCheck both logged in and logged out
Previews statusdesktopwebuiactionstrackingevent.is_page_preview_on (Boolean)If page preview is enabled, returns true, otherwise falseCheck both logged in and logged out
interface width statusdesktopwebuiactionstrackingevent.is_full_width (Boolean)If full width, return true, otherwise falseCheck both logged in and logged out
pinneddesktopwebuiactionstrackingevent.is_pinned (Boolean)If at least one pinnable component is pinned, return true, otherwise falseCheck both logged in and logged out
media viewer statusdesktopwebuiactionstrackingevent.is_media_viewer_enabled (Boolean)If media viewer is enabled via the console or the thumbnail, return true, otherwise falseCheck both logged in and logged out
OS Dark Mode Settingdesktopwebuiactionstrackingevent.is_dark_mode_preferred_by_osToggling OS settings for dark mode returns true or false (Instructions)Check both logged in and logged out
Dark Modedesktopwebuiactionstrackingevent.is_dark_mode_onFor now, should always return falseCheck both logged in and logged out

Change 965246 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[operations/mediawiki-config@master] Beta cluster: mobile web click tracking schema at 100%

https://gerrit.wikimedia.org/r/965246

Change 965258 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[schemas/event/secondary@master] Refactor schema structure

https://gerrit.wikimedia.org/r/965258

Edtadros subscribed.

Test Result - Beta

Status: ✅ PASS
Environment: beta
OS: macOS Sonoma
Browser: Chrome
Device: MBA
Emulated Device:NA

Test Artifact(s):

QA Steps

QA Instructions

  1. Validate the event tracking and data collection as outlined in the following tables.
  2. Test both logged-in and logged-out states.
  3. Mobile has additional new fields because it now shares a new fragment with desktop, so it will also have is_pinned, is_media_viewer_enabled, etc. This is expected behavior.

Minerva (Mobile)

✅ AC1: Minerva logged in
✅ AC2: Minerva logged out

DescriptionSchemaFieldsExpected ResultsLogged InLogged Out
Number of pageviewsMobileWebUIActionsTrackingevent.action="init"On load, the init event should always fire.
Session IDMobileWebUIActionsTrackingevent.tokenToken field must always be included
Skin nameMobileWebUIActionsTrackingevent.skin='minerva'Skin field must always be included
Font sizeMobileWebUIActionsTrackingevent.fontFor now, should always return false
Logged InLogged Out
loggedinmobile.png (1×1 px, 246 KB)
anonmobile.png (1×1 px, 210 KB)

Vector 2022 (Desktop)

✅ AC3: Vector 2022 logged in
✅ AC4: Vector 2022 logged out

DescriptionSchemaFieldsExpected ResultsLogged InLogged Out
Number of pageviewsdesktopwebuiactionstrackingevent.action="init"On load, the init event should always fire.
Session IDdesktopwebuiactionstrackingevent.tokenToken field must always be included
Skin namedesktopwebuiactionstrackingevent.skin='vector-2022'Skin field must always be included
Previews statusdesktopwebuiactionstrackingevent.is_page_preview_on (Boolean)If page preview is enabled, returns true, otherwise false
interface width statusdesktopwebuiactionstrackingevent.is_full_width (Boolean)If full width, return true, otherwise false
pinneddesktopwebuiactionstrackingevent.is_pinned (Boolean)If at least one pinnable component is pinned, return true, otherwise false
media viewer statusdesktopwebuiactionstrackingevent.is_media_viewer_enabled (Boolean)If media viewer is enabled via the console or the thumbnail, return true, otherwise false
OS Dark Mode Settingdesktopwebuiactionstrackingevent.is_dark_mode_preferred_by_osToggling OS settings for dark mode returns true or false (Instructions)
Dark Modedesktopwebuiactionstrackingevent.is_dark_mode_onFor now, should always return false
Logged InLogged Out
loggedindesktop.png (1×1 px, 226 KB)
loggedoutdesktop.png (1×953 px, 211 KB)

Change 965258 merged by jenkins-bot:

[schemas/event/secondary@master] Refactor schema structure

https://gerrit.wikimedia.org/r/965258

Change 965246 merged by jenkins-bot:

[operations/mediawiki-config@master] Beta cluster: mobile web click tracking schema at 100%

https://gerrit.wikimedia.org/r/965246

Hi folks! After an unrelated deployment of EventGate analytics-external a lot of validation errors appeared:

https://grafana.wikimedia.org/d/ZB39Izmnz/eventgate?orgId=1&var-service=eventgate-analytics-external&var-stream=All&var-kafka_broker=All&var-kafka_producer_type=All&var-dc=thanos&from=now-3h&to=now&refresh=1m&viewPanel=75

  • DesktopWebUIActionsTracking -> "message": "'.event.font' should be string",
  • MobileWebUIActionsTracking -> "message":"'.event.font' should be string"

In both cases the schema seems to be the one created with https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/960141. The change has been merged before the MediaWiki deployment, and our (unrelated) restart of the Eventgate service forced a refresh. Should we revert the change before the MW Deployment to stop the errors?

I've left two comments on https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikimediaEvents/+/95a8594, one of which caused the "'.event.font' should be string" validation error and another that caused a relatively small number of events to be sent with is_page_previews_enabled=null.

Edit

Sorry… I reverted that patch and scap backported it. The validation errors very quickly tailed off:

https://logstash.wikimedia.org/goto/3ed5d68762e7f907df25993e02c48c54

Change 966262 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[mediawiki/extensions/Popups@master] mw.popups.isEnabled should always return boolean

https://gerrit.wikimedia.org/r/966262

Change 966262 merged by jenkins-bot:

[mediawiki/extensions/Popups@master] mw.popups.isEnabled should always return boolean

https://gerrit.wikimedia.org/r/966262

Change 966278 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[schemas/event/secondary@master] Schema bump desktop and mobile web ui

https://gerrit.wikimedia.org/r/966278

Change 966278 merged by jenkins-bot:

[schemas/event/secondary@master] Schema bump desktop and mobile web ui

https://gerrit.wikimedia.org/r/966278

Change 966229 had a related patch set uploaded (by Jdlrobson; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@master] Introduce Web Accessibility Features and Submodule (attempt 2)

https://gerrit.wikimedia.org/r/966229

Change 966229 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] Introduce Web Accessibility Features and Submodule (attempt 2)

https://gerrit.wikimedia.org/r/966229

@jwang The latest revert we made should be testable in test.wikipedia.org tomorrow. Sampling there is at 100% so we should see some entries in the database starting tomorrow as part of QA.
@Edtadros You should be able to QA that events are firing in the network tab again just to make sure we didn't accidentally undo anything in test wiki.

Mabualruz assigned this task to Edtadros.
Mabualruz updated Other Assignee, added: KSarabia-WMF; removed: Jdlrobson.

Change 966630 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@master] Fix Typo in OS Dark Mode field

https://gerrit.wikimedia.org/r/966630

Change 966630 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] Fix Typo in OS Dark Mode field

https://gerrit.wikimedia.org/r/966630

Change 966615 had a related patch set uploaded (by Jdlrobson; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@wmf/1.42.0-wmf.1] Fix Typo in OS Dark Mode field

https://gerrit.wikimedia.org/r/966615

Change 966615 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@wmf/1.42.0-wmf.1] Fix Typo in OS Dark Mode field

https://gerrit.wikimedia.org/r/966615

Mentioned in SAL (#wikimedia-operations) [2023-10-18T18:03:45Z] <brennen@deploy2002> Started scap: Backport for [[gerrit:966615|Fix Typo in OS Dark Mode field (T346106)]]

Mentioned in SAL (#wikimedia-operations) [2023-10-18T18:05:08Z] <brennen@deploy2002> brennen and jdlrobson: Backport for [[gerrit:966615|Fix Typo in OS Dark Mode field (T346106)]] synced to the testservers (https://wikitech.wikimedia.org/wiki/Mwdebug)

Mentioned in SAL (#wikimedia-operations) [2023-10-18T18:17:31Z] <brennen@deploy2002> Finished scap: Backport for [[gerrit:966615|Fix Typo in OS Dark Mode field (T346106)]] (duration: 13m 46s)

Test Result - Prod

Status: ✅ PASS
Environment: testwiki
OS: macOS Sonoma
Browser: Chrome
Device: MBA
Emulated Device:NA

Test Artifact(s):

QA Steps

QA Instructions

  1. Validate the event tracking and data collection as outlined in the following tables.
  2. Test both logged-in and logged-out states.
  3. Mobile has additional new fields because it now shares a new fragment with desktop, so it will also have is_pinned, is_media_viewer_enabled, etc. This is expected behavior.

Minerva (Mobile)

✅ AC1: Minerva logged in
✅ AC2: Minerva logged out

DescriptionSchemaFieldsExpected ResultsLogged InLogged Out
Number of pageviewsMobileWebUIActionsTrackingevent.action="init"On load, the init event should always fire.
Session IDMobileWebUIActionsTrackingevent.tokenToken field must always be included
Skin nameMobileWebUIActionsTrackingevent.skin='minerva'Skin field must always be included
Font sizeMobileWebUIActionsTrackingevent.fontFor now, should always return false
Logged InLogged Out
screenshot 133ml.png (1×985 px, 209 KB)
screenshot 129ma.png (1×976 px, 193 KB)

Vector 2022 (Desktop)

✅ AC3: Vector 2022 logged in
✅ AC4: Vector 2022 logged out

DescriptionSchemaFieldsExpected ResultsLogged InLogged Out
Number of pageviewsdesktopwebuiactionstrackingevent.action="init"On load, the init event should always fire.
Session IDdesktopwebuiactionstrackingevent.tokenToken field must always be included
Skin namedesktopwebuiactionstrackingevent.skin='vector-2022'Skin field must always be included
Previews statusdesktopwebuiactionstrackingevent.is_page_preview_on (Boolean)If page preview is enabled, returns true, otherwise false
interface width statusdesktopwebuiactionstrackingevent.is_full_width (Boolean)If full width, return true, otherwise false
pinneddesktopwebuiactionstrackingevent.is_pinned (Boolean)If at least one pinnable component is pinned, return true, otherwise false
media viewer statusdesktopwebuiactionstrackingevent.is_media_viewer_enabled (Boolean)If media viewer is enabled via the console or the thumbnail, return true, otherwise false
OS Dark Mode Settingdesktopwebuiactionstrackingevent.is_dark_mode_preferred_by_osToggling OS settings for dark mode returns true or false (Instructions)
Dark Modedesktopwebuiactionstrackingevent.is_dark_mode_onFor now, should always return false
Logged InLogged Out
screenshot 132dl.png (1×978 px, 225 KB)
screenshot 130da.png (1×982 px, 229 KB)

Ran some queries and their responses seemed reasonable so I think this looks good enough to pass to Jennifer. Thanks for all the work here! Interestingly 20% of all users have the dark mode operating system setting enabled.

Change 968674 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[schemas/event/secondary@master] Adds skin field in mobilewebuiactions

https://gerrit.wikimedia.org/r/968674

Change 968675 had a related patch set uploaded (by Kimberly Sarabia; author: Kimberly Sarabia):

[mediawiki/extensions/WikimediaEvents@master] Updates schema version for mobilewebuiactions

https://gerrit.wikimedia.org/r/968675