Dario attempted to respond but mailman is bouncing his message. Posting on his behalf.
From: Dario Taraborelli dtaraborelli@wikimedia.org Subject: Re: [Wikitech-l] Anonymous user id on wikipedia? Date: December 18, 2012 2:09:56 PM PST To: Wikimedia developers wikitech-l@lists.wikimedia.org
To further clarify the use of this randomly assigned token, we use mediawiki.user.id to count client events that occur as part of a given funnel. For example: we count impressions, button clicks or submit events to measure whether an experimental version of a feature has a higher conversion rate than the default version. We rely on tokens to be able to deduplicate event counts and make sure that when users reload a form multiple times this doesn't affect conversion measurements. These measurements are being used to optimize feature design and to assess the impact of small experiments run by the Foundation's editor engagement teams.
As Kevin notes, the cookie is set by the mw.user.id() function – which you can call and test in your browser's JS console – and it persists across browser sessions. The function is currently called by a number of extensions that need to set a token and assign users to a bucket or test condition as part of testing.
Dario
-- Ori Livneh
On Tuesday, December 18, 2012 at 1:41 PM, Kevin Israel wrote:
On 12/18/2012 03:28 PM, Tyler Romeo wrote:
- This I have no idea about, but it's definitely not in the core, because
my test wiki doesn't set this cookie. It has to be an extension.
Merely calling the mediaWiki.user.id() JavaScript function, which was introduced into core MediaWiki in https://www.mediawiki.org/wiki/Special:Code/MediaWiki/78539 , sets the one-year cookie. Nothing in core MW (except for the corresponding QUnit test) actually uses the function.
However, the following code in extensions/E3Experiments/experiments/openTask.js does call that function. I can confirm this code is executed merely by loading Wikipedia's Main Page.
// FIXME for anons, calling mw.user.id() simply ensures the // "mediaWiki.user.id" cookie is set, if it isn't already. if ( !$.cookie( 'mediaWiki.user.id' ) ) { if ( mw.user.id() === mw.user.getName() ) { $.cookie( 'mediaWiki.user.id', generateId(), { expires: 365, path: '/' } ); } }
- That is done on purpose. It's a convenience feature. Notice how when you
logout and then go back to the login page that your username is already filled in for you. AFAIK, it isn't used in any way by MediaWiki to identify the user.
Even if you do not check "Remember my login on this browser", the username is saved for 180 days (which, by the way, is four times the duration set out in the WMF privacy policy). As far as I can tell, this "feature" has existed at least since the phase3 reorg in 2003, if not before then.
-- Wikipedia user PleaseStand http://en.wikipedia.org/wiki/User:PleaseStand
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org (mailto:Wikitech-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/wikitech-l