Last modified: 2014-02-12 23:45:15 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 T53465, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 51465 - Switching to mobile view and back leaves cookie behind
Switching to mobile view and back leaves cookie behind
Status: RESOLVED WONTFIX
Product: MobileFrontend
Classification: Unclassified
Feature requests (Other open bugs)
unspecified
All All
: Low enhancement
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-16 19:48 UTC by Carl Fürstenberg
Modified: 2014-02-12 23:45 UTC (History)
10 users (show)

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


Attachments
Illustration of why desktop banners should not be served to mobile users (151.35 KB, image/png)
2013-07-26 18:03 UTC, Matt Walker
Details

Description Carl Fürstenberg 2013-07-16 19:48:06 UTC
If someone is clicking on "Mobile View" and then back to "Desktop", a stopMobileRedirect cookie is left behind. This cookie will disable central notices on all wikimedia sites perpetually
Comment 1 Matt Walker 2013-07-16 19:51:12 UTC
Fundraising's initial response is going to be just to just remove the filtering -- however, it would be a good feature for mobile frontend if that cookie was somewhat smarter (enough to remove itself when not needed / or track where it came from originally: varnish vs url click.)

Removing the filtering comes at the expense of potentially exposing users to banners that don't work particularly well on small screens.
Comment 2 Gerrit Notification Bot 2013-07-16 19:56:30 UTC
Change 73999 had a related patch set uploaded by Mwalker:
(Bug 51465) No Longer Filtering Mobile Devices

https://gerrit.wikimedia.org/r/73999
Comment 3 Gerrit Notification Bot 2013-07-16 20:16:41 UTC
Change 73999 merged by jenkins-bot:
(Bug 51465) No Longer Filtering Mobile Devices

https://gerrit.wikimedia.org/r/73999
Comment 4 Jon 2013-07-17 17:34:03 UTC
Just to check I understand the problem correctly:
You want to show a banner on the desktop site (en.wikipedia.org and friends) when viewed in a mobile phone?
Was there any reason you didn't do this before? I don't really understand the logic... ResourceLoader disables JavaScript on older phones so these banners should work perfectly fine.

Could you clarify "Removing the filtering comes at the expense of potentially exposing users to banners that don't work particularly well on small screens." - if a mobile views the desktop site on their phone they will either use a modified viewport [1] and the banner will look exactly the same as desktop, or if there is no viewport the entire website will be unreadable so I'd be surprised they'd even be in desktop mode.

Does this effect the mobile site (en.m.wikipedia.org and friends) in anyway?

I'm also unclear how this effects the VisualEditor roll out... (you mention this in the CentralNotice fix).

The stopMobileRedirect cookie exists for a reason - if a user of the mobile site wants to see the desktop site this stops them from being redirected on every visit.

We could only set the stopMobileRedirect cookie if the user is on a mobile phone but this is messy and I don't see what value the work put in to achieve this would gain. Does anything really need to change in MobileFrontend now?

[1] http://www.quirksmode.org/mobile/viewports2.html
Comment 5 Matt Walker 2013-07-17 20:13:07 UTC
(In reply to comment #4)
> You want to show a banner on the desktop site (en.wikipedia.org and friends)
> when viewed in a mobile phone?

Nope -- we want to show a banner on the desktop site to a desktop user who has previously used the mobile interface.

> Could you clarify "Removing the filtering comes at the expense of potentially
> exposing users to banners that don't work particularly well on small
> screens."

With CentralNotice not filtering; true mobile users who choose to use the desktop site may be presented with a banner that doesn't work on small screens - e.g. the buttons are too small to hit with a finger.

> Does this effect the mobile site (en.m.wikipedia.org and friends) in anyway?

No. Only the desktop site (and the transition of a desktop user between that and the mobile site and back.)

> I'm also unclear how this effects the VisualEditor roll out... (you mention
> this in the CentralNotice fix).

VE is only involved because we spotted it with a VE banner (they want to show to everyone so we're getting lots of interesting CN bugs.)

> The stopMobileRedirect cookie exists for a reason - if a user of the mobile
> site wants to see the desktop site this stops them from being redirected on
> every visit.

Yep, understood. The feature request is more to not return 'desktop' devices to the desktop site after having viewed the mobile site with a stopMobileRedirect cookie.

> We could only set the stopMobileRedirect cookie if the user is on a mobile
> phone but this is messy and I don't see what value the work put in to achieve
> this would gain. Does anything really need to change in MobileFrontend now?

Meh; don't know. This is an edge case... It's more related to if we have more things that are device dependent using the cookie to determine if someone is on a big device or not.
Comment 6 Jon 2013-07-17 22:04:47 UTC
"With CentralNotice not filtering; true mobile users who choose to use the
desktop site may be presented with a banner that doesn't work on small screens
- e.g. the buttons are too small to hit with a finger."

This is a non-issue
The banner will be exactly the same size for users viewing the desktop site on a mobile device.
Comment 7 Matt Walker 2013-07-26 18:03:26 UTC
Created attachment 12978 [details]
Illustration of why desktop banners should not be served to mobile users

Adam got this whilst browsing on the desktop site on his phone whilst logged out.
Comment 8 Jon 2013-07-26 19:20:09 UTC
Is that zoomed in?
Does it disappear when you scroll?
Is it fixed position or absolute?

How can one access that banner on a phone - is there a url? Looks like with a few tweaks to the css that should be easy render correctly on a desktop view on a mobile screen...
Comment 9 Arthur Richards 2013-08-19 22:15:15 UTC
I'm marking this as wontfix.

While I see your point about not setting the stopMobileRedirect cookie for devices that wouldn't normally get automatically redirected (eg a desktop browser), we don't have a reliable way to detect that, so without rearchitecting, we can't really achieve this. Ultimately, we've been attempting to simplify how MobileFrontend works - partly for performance/caching reasons and partly for codebase sanity, and I do not think this usecase is compelling enough to warrant additional complexity.

I suspect Jon is right that with some CSS magic you may be able to resolve the specific issues you're running into with the banners. Otherwise, we should have a bigger discussion about how best for you guys to achieve what you need from within CentralNotice.

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


Navigation
Links