Last modified: 2014-02-12 23:52:49 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 T50490, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 48490 - wgMFMode lies
wgMFMode lies
Status: RESOLVED FIXED
Product: MobileFrontend
Classification: Unclassified
stable (Other open bugs)
unspecified
All All
: Unprioritized normal
: ---
Assigned To: Jon
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-15 02:14 UTC by Jon
Modified: 2014-02-12 23:52 UTC (History)
9 users (show)

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


Attachments

Description Jon 2013-05-15 02:14:06 UTC
Due to a refactor of config variables as a result of bug 44133 I stupidly put wgMFMode inside the resource loader javascript module instead of in the page HTML. Since javascript doesn't vary in alpha/beta/stable this means the value caches and cannot be relied on.

More on this after I've applied a live hack..
Comment 1 Jon 2013-05-15 02:26:18 UTC
Stable pages are more likely to be cached so in theory the major damage this causes is that EventLogging data will be wrong whilst this bug is in place in that it might report an event happened in alpha when it happened in stable.

Added live hack: https://en.m.wikipedia.org/wiki/MediaWiki:Mobile.js
Page HTML does vary. I think we should set the config variable this way in application.js and not add it via the hook.

As a result hopefully damage is minimal.

Note this doesn't cause alpha or beta modules to get added to stable - it simply has side effects to code which is not properly sandboxed. Potential problems that might arise due to lack of sandboxing:

* The edit button code is in stable and relies on wgMFMode to decide whether to show. As a result there is a chance logged in users might see an edit link on stable (anon users luckily won't)
* Nearby watchlist star may or may not show
* A logged in user might see a toast message welcoming him/her to the site
* Unified diffs might possibly show in stable.
* The nag overlay might show in stable

Fix on way...
Comment 2 Gerrit Notification Bot 2013-05-15 02:36:49 UTC
Related URL: https://gerrit.wikimedia.org/r/63822 (Gerrit Change Ic5f45299e57fa55f1b95ca1753a488b9c4bf7b18)
Comment 3 Arthur Richards 2013-05-15 16:51:30 UTC
(In reply to comment #1)
> Stable pages are more likely to be cached so in theory the major damage this
> causes is that EventLogging data will be wrong whilst this bug is in place in
> that it might report an event happened in alpha when it happened in stable.

For the record, stable pages are the ONLY pages that get cached - if you're in alpha or beta, you *always* bypass mobile varnish caching.
Comment 4 Gerrit Notification Bot 2013-05-15 17:42:19 UTC
https://gerrit.wikimedia.org/r/63822 (Gerrit Change Ic5f45299e57fa55f1b95ca1753a488b9c4bf7b18) | change APPROVED and MERGED [by jenkins-bot]

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


Navigation
Links