Page MenuHomePhabricator

Make it possible to deploy welcomesurvey to % of users that's not divisible by 10
Closed, ResolvedPublic

Description

Background

In T281896#7128285 (and related Slack thread), @MMiller_WMF requested welcome survey to be deployed to 2% of English Wikipedia newcomers.

It looks the code from https://w.wiki/3RTX doesn't allow an arbitrary percentage yet. The code requires amount of welcomesurvey-enabled newcomers to be specified as 0-n, where n is a natural number smaller than 10. The code then generates a random natural number m smaller than 10, and checks if m <= n. If it is, it shows welcomesurvey, if m > n, no welcomesurvey is shown.

That means as-of now, the percentage of WS-enabled newcomers needs to be divisable by 10 (in another words, we can deploy WS to 0% of users, 10% of users or 40% of users, but not to 45% or 2%, as neither 45 nor 2 can be divided by 10).

Task objective

Change https://w.wiki/3RTX to use a similar system to wgGEHomepageNewAccountEnablePercentage – specify a percentage (ie. n <= 100) instead of a range, which will allow us to be more flexible.

Filling this as a blocker to T281896: Deploy Growth features on English Wikipedia, as the requirements of T281896 cannot be met without this task completed.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
kostajh triaged this task as Medium priority.Jun 2 2021, 8:50 AM
kostajh subscribed.

@Urbanecm_WMF is this something you want to take on?

@Urbanecm_WMF is this something you want to take on?

Sure, as it's closely related to the enwiki deployment I'll be working on.

Change 697922 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/extensions/GrowthExperiments@master] Make it possible to deploy welcomesurvey to % of users that's not divisible by 10

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

Change 697922 merged by jenkins-bot:

[mediawiki/extensions/GrowthExperiments@master] Make it possible to deploy welcomesurvey to % of users that's not divisible by 10

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

Change 698364 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/extensions/GrowthExperiments@wmf/1.37.0-wmf.7] Make it possible to deploy welcomesurvey to % of users that's not divisible by 10

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

Change 698364 merged by jenkins-bot:

[mediawiki/extensions/GrowthExperiments@wmf/1.37.0-wmf.7] Make it possible to deploy welcomesurvey to % of users that's not divisible by 10

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

Mentioned in SAL (#wikimedia-operations) [2021-06-07T18:22:41Z] <urbanecm@deploy1002> Synchronized php-1.37.0-wmf.7/extensions/GrowthExperiments/extension.json: 368b5d9: 0e79aee: WelcomeSurvey backports (T284127, T284257; 1/2) (duration: 00m 56s)

Mentioned in SAL (#wikimedia-operations) [2021-06-07T18:24:17Z] <urbanecm@deploy1002> Synchronized php-1.37.0-wmf.7/extensions/GrowthExperiments/includes/WelcomeSurvey.php: 368b5d9: 0e79aee: WelcomeSurvey backports (T284127, T284257; 2/2) (duration: 00m 57s)