Page MenuHomePhabricator

Instrument event-logging data for ArticleCreationWorkflow
Closed, ResolvedPublic3 Estimated Story Points

Description

For the ACTRIAL experiment: we want to know how many people view the landing page, and then how many clicks there are on each button and link from the landing page.

https://www.mediawiki.org/wiki/Extension:EventLogging

Event Timeline

We might get the pageview data for free. I know that http://tools.wmflabs.org/pageviews/ supports page views for special pages, but I'm not sure how it deals with subpages (like Special:CreatePage/Puppies). Maybe @MusikAnimal would know. Do subpage page views roll-up into the parent page stats? I bet they don't. Is there any way to view the page views for a page and all it's subpages?

We might get the pageview data for free. I know that http://tools.wmflabs.org/pageviews/ supports page views for special pages, but I'm not sure how it deals with subpages (like Special:CreatePage/Puppies). Maybe @MusikAnimal would know. Do subpage page views roll-up into the parent page stats? I bet they don't. Is there any way to view the page views for a page and all it's subpages?

As far as I know any page that goes through Varnish should be recorded, including Special pages. Subpages definitely don't bubble up to the parent, that much I'm sure. See example of Special:Log vs Special:Log/block: http://tools.wmflabs.org/pageviews/?project=en.wikipedia.org&platform=all-access&agent=user&range=latest-20&pages=Special:Log|Special:Log/block

Is there any way to view the page views for a page and all it's subpages?

Massviews does this, but going by the MediaWiki API it doesn't know about "subpages" of Special pages (if you really want to call them subpages). I'm not sure how to automate detection of these pages. If we can figure that out I can fix Massviews to support it.

Hmm, this might be a lot harder than I thought. The pageview stats are going to be different for every page title, so there's no easy way to roll it up without doing some expensive queries on the raw pageview data. Also, it doesn't look like there's any way to execute JavaScript from the clickable button template. We would have to add some JS to common.js which would bloat page load for everyone. I'm wondering if we should re-think making the entire page live on-wiki, as this makes analytics difficult.

After talking with @MaxSem, we've decided to append the requested page title as a query string parameter rather than as a subpage so that we get pageview data for free via the pageview API.

Change 372903 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[mediawiki/extensions/ArticleCreationWorkflow@master] Specify page being created as a URL parameter

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

Change 372903 merged by jenkins-bot:
[mediawiki/extensions/ArticleCreationWorkflow@master] Specify page being created as a URL parameter

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

DannyH edited projects, added Community-Tech-Sprint; removed Community-Tech.
DannyH set the point value for this task to 3.

Change 374436 had a related patch set uploaded (by Niharika29; owner: Niharika Kohli):
[mediawiki/extensions/ArticleCreationWorkflow@master] Add eventlogging for link clicks on Special:CreatePage

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

Change 374436 merged by jenkins-bot:
[mediawiki/extensions/ArticleCreationWorkflow@master] Add eventlogging for link clicks on Special:CreatePage

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