Last modified: 2013-01-22 02:26:27 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T45107, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 43107 - test.wikipedia.org does not serve correct messages to JS after GettingStarted extension deploy
test.wikipedia.org does not serve correct messages to JS after GettingStarted...
Status: RESOLVED WORKSFORME
Product: Wikimedia
Classification: Unclassified
General/Unknown (Other open bugs)
wmf-deployment
All All
: High normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-12-14 01:05 UTC by Matthew Flaschen
Modified: 2013-01-22 02:26 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Matthew Flaschen 2012-12-14 01:05:38 UTC
We deployed GettingStarted to test.wikipedia.org using the process at http://wikitech.wikimedia.org/view/How_to_deploy_code#Case_1d:_new_extension , and enabled it on test.wikipedia.org.

However, ResourceLoader did not (and still doesn't, as of now) serve the correct messages to JS.  Both http://test.wikipedia.org/w/load.php?debug=false&lang=en&modules=ext.gettingstarted.accountcreation&skin=vector&version=20121218T214605Z&* and http://test.wikipedia.org/w/load.php?debug=true&lang=en&modules=ext.gettingstarted.accountcreation&skin=vector&version=20121218T214605Z&* (debug false and true) serve the placeholder messages:

{"gettingstarted-welcomesiteuser":"<gettingstarted-welcomesiteuser>","gettingstarted-backtoarticle":"<gettingstarted-backtoarticle>"}

When we enabled English Wikipedia and synced there, it worked fine (again, regardless of debug).

I'm filing it here since it is not a straight bug in ResourceLoader, but config-dependent.
Comment 1 Andre Klapper 2012-12-14 10:28:57 UTC
Different results here, close as WORKSFORME?

With debug=true:

mw.loader.implement("ext.gettingstarted.accountcreation", ["//test.wikipedia.org/w/static-1.21wmf6/extensions/GettingStarted/resources/ext.gettingstarted.accountcreation.js"], {}, {"gettingstarted-welcomesiteuser":"Welcome to $1, $2!","gettingstarted-backtoarticle":"No thanks, back to article"});

With debug=false:

mw.loader.implement("ext.gettingstarted.accountcreation",function(){(function($,mw){$(function(){var title=mw.msg('gettingstarted-welcomesiteuser',mw.config.get('wgSiteName'),mw.config.get('wgUserName'));document.title=title;$('#firstHeading span').text(title);var $returnTo=$('#mw-returnto');var returnToUrl=$('a',$returnTo).attr('href');$returnTo.remove();var $returnToAgora=$('<a />',{id:'back-to-referrer',href:returnToUrl,'class':'blue mw-ui-button',text:'← '+mw.msg('gettingstarted-backtoarticle')});$('#onboarding-header p').append($returnToAgora);var state={};var url=mw.util.wikiGetlink('Special:GettingStarted');if(history.replaceState){history.replaceState(state,title,url);}});})(jQuery,mediaWiki);;},{},{"gettingstarted-welcomesiteuser":"Welcome to $1, $2!","gettingstarted-backtoarticle":"No thanks, back to article"});
/* cache key: testwiki:resourceloader:filter:minify-js:7:0540b98b5c698de4af3e5f932a9d5e57 */
Comment 2 Matthew Flaschen 2012-12-14 18:30:35 UTC
It's interesting that it works now, but that still indicates a problem with cache eviction.  It worked on English Wikipedia immediately after we enabled it, but still didn't work on test then (even though test was enabled first).

The fact that it worked hours later on test.wiki may give us useful information, but there's still a bug.  The point of test.wiki is to test before deploying to a real wiki.
Comment 3 spage 2012-12-14 22:16:21 UTC
Steven Walling comments that our Extension:PostEdit deploy had a similar problem with missing messages on test.w.o during and after deployment.

If I repeat the request above:

curl --dump-header - 'http://test.wikipedia.org/w/load.php?debug=false&lang=en&modules=ext.gettingstarted.accountcreation&skin=vector&version=20121213T214605Z&*'

I still get the incorrect code. The headers are:

HTTP/1.0 200 OK
Date: Thu, 13 Dec 2012 23:40:59 GMT
Server: Apache
X-Content-Type-Options: nosniff
Cache-Control: private, s-maxage=0, max-age=0, must-revalidate
Last-Modified: Thu, 13 Dec 2012 21:46:05 GMT
Expires: Sat, 12 Jan 2013 23:40:59 GMT
Vary: Accept-Encoding
Content-Length: 946
Content-Type: text/javascript; charset=utf-8
Age: 80701
X-Cache: HIT from cp1012.eqiad.wmnet
X-Cache-Lookup: HIT from cp1012.eqiad.wmnet:3128
X-Cache: MISS from cp1002.eqiad.wmnet
X-Cache-Lookup: MISS from cp1002.eqiad.wmnet:80
Connection: close

The i18n.php, CSS, and JS files on fenari are dated 2012-12-13 21:08, so I don't understand why RL requests made  30 minutes later don't find the i18n strings from the PHP.  This is a real bug... somewhere.
Comment 4 Krinkle 2012-12-14 22:19:50 UTC
Did you rebuild i18n cache ? (using scap and/or the dedicated scripts).

We don't read i18n files directly on the cluster, they are cached. ResourceLoader, wfMsg etc. they all interface with the cache. Not the raw files.

And we disabled automatic cache refreshing. Instead we build them for all extensions at once periodically, this is not ResourceLoader related afaik.
Comment 5 Matthew Flaschen 2012-12-14 22:27:39 UTC
We did first tried http://wikitech.wikimedia.org/view/How_to_deploy_code#Alternative_to_scap

But after that, we did a full scap, with test.wiki enabled, and the strings were still out of date.  The original symptom was that these placeholder JS strings actually showed up in the interface

However, the same messages worked using transclusion (https://test.wikipedia.org/wiki/User:Superm401/Sandbox).
Comment 6 Ori Livneh 2013-01-22 02:26:27 UTC
To my knowledge, this problem has not recurred.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links