Closed Bug 1555035 Opened 5 years ago Closed 1 month ago

Add USER_AGENT_MODE_TABLET

Categories

(GeckoView :: General, defect, P3)

Unspecified
Android

Tracking

(firefox67 wontfix, firefox67.0.1 wontfix, firefox68 wontfix, firefox69 wontfix, firefox70 wontfix)

RESOLVED WONTFIX
Tracking Status
firefox67 --- wontfix
firefox67.0.1 --- wontfix
firefox68 --- wontfix
firefox69 --- wontfix
firefox70 --- wontfix

People

(Reporter: sebastian, Unassigned)

References

Details

The platform part of the UA string indicates if Firefox is running on a phone-sized or tablet device. When Firefox runs on a device that has the phone form factor, there is a Mobile; token in the platform part of the UA string. When Firefox runs on a tablet device, there is a Tablet; token in the platform part of the UA string instead.

Mozilla/5.0 (Android 4.4; Mobile; rv:41.0) Gecko/41.0 Firefox/41.0
Mozilla/5.0 (Android 4.4; Tablet; rv:41.0) Gecko/41.0 Firefox/41.0

We already support setting USER_AGENT_MODE_MOBILE and USER_AGENT_MODE_DESKTOP. We may want to add a USER_AGENT_MODE_TABLET flag.
https://mozilla.github.io/geckoview/javadoc/mozilla-central/org/mozilla/geckoview/GeckoSessionSettings.html#USER_AGENT_MODE_DESKTOP

We may want to let this go. Android tablet market share is not large. Having a different user agent for a small percentage of the users makes supporting Firefox on Android more complicated.

NI-ing Mike Talyor for input since he commented on the Fenix issue:

This affects the experience on Bing, probably on a lot of other sites.

Flags: needinfo?(miket)

We probably need Product sign off to make a decision to not include it.

See https://docs.google.com/document/d/1j2vWthNQ4QWigXdQJ-YB4l_P06OZhCM5tp0quqKFKgc/edit#heading=h.5l302h3mvorn.

We could send a UA override for bing (whenever we will have that capability), and attempt outreach, but we probably need to test other top sites (google properties for sure).

Andreas, WDYT?

Flags: needinfo?(miket) → needinfo?(abovens)

I think we need to differentiate between mobile and tablet. 15% of Fennec users uses Fennec on a tablet, so it's a not insignificant portion of our user base. This might be somewhat different in Fenix of course, but still.

Flags: needinfo?(abovens)

Thanks Andreas. I think in order to be consistent with Fennec, we should also support USER_AGENT_MODE_TABLET.

We could revisit in the future, but I'd prefer to not fork on UA string behavior just for tablets.

Flags: needinfo?(s.kaspari)

If we're going to add USER_AGENT_MODE_TABLET, we should probably add USER_AGENT_MODE_TV for completeness. Gecko has code to add "TV" to the User-Agent string:

https://searchfox.org/mozilla-central/rev/7556a400affa9eb99e522d2d17c40689fa23a729/netwerk/protocol/http/nsHttpHandler.cpp#1002-1015

Priority: -- → P2
Whiteboard: [geckoview:fenix:m7]

TV-specific content is not a thing, so it probably doesn't make a whole lot of sense. TV is similar to tablet/desktop in terms of form factor, with perhaps a Device-Pixel Ratio of 1.5, so just giving it a desktop or tablet UA string makes more sense.

Will this make GV 68?

Looking at the webcompat issues referencing the Fenix issue a bunch of people seem to care about Bing not working:
https://github.com/mozilla-mobile/fenix/issues/1848

Flags: needinfo?(s.kaspari)

(In reply to Sebastian Kaspari (:sebastian; :pocmo) from comment #8)

Will this make GV 68?

Looking at the webcompat issues referencing the Fenix issue a bunch of people seem to care about Bing not working:
https://github.com/mozilla-mobile/fenix/issues/1848

(Note: those reports were reported by our SV team while doing some top site testing, so take the quantity with a grain of salt.)

(In reply to Sebastian Kaspari (:sebastian; :pocmo) from comment #8)

Will this make GV 68?

No. We don't plan to work on this for GV 68 because the Fenix issue is only priority P3 and not labeled "MVP Blocker". But let me know if that changes. :)

https://github.com/mozilla-mobile/fenix/issues/1848

Deferring this bug from Fenix's M7 (July) milestone to the M8 backlog for later in Q3.

Whiteboard: [geckoview:fenix:m7] → [geckoview:fenix:m8]

not Q3

Whiteboard: [geckoview:fenix:m8] → [geckoview:fenix:m9]

This might be a good first bug.

Rank: 59
Keywords: good-first-bug
Whiteboard: [geckoview:fenix:m9]
Priority: P2 → P3

Removing good-first-bug because we will probably change Fenix's tablet UA string soon.

Keywords: good-first-bug
OS: All → Android
See Also: → 1790516
Severity: normal → S3
Rank: 59 → 333

Has this been implemented recently? Version 109 has caused websites to serve desktop (tablet?) versions on my Surface Duo. Please see 1807209 for details.

(In reply to Jamie Kitson from comment #15)

Has this been implemented recently? Version 109 has caused websites to serve desktop (tablet?) versions on my Surface Duo. Please see 1807209 for details.

Thanks for reporting this issue. The Tablet problem in bug 1809221 has been fixed separately.

Instead of implementing this Tablet UA string, we may decide to send Firefox desktop's UA string on tablets (bug 1790516), similar to how iPad Safari sends a macOS Safari UA string.

See Also: → 1809221

This bug has been superseded by bug 1790516 to default to a desktop UA string on tablets (like Safari on iPad and Chrome on "premium" tablets) instead of restoring legacy Fennec's Tablet UA string in Fenix. Since neither Safari's nor Chrome's UA strings on tablets include a "Tablet" token, including one in Fenix would be risky because it would trigger web code paths that might not be well-tested because they're not used for Safari or Chrome.

Status: NEW → RESOLVED
Closed: 1 month ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.