B2G User Agent

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

B2G User Agent

Gervase Markham
Yes, it's User Agent string time again, this time for B2G. There is
actually quite a bit of rough consensus, and the outstanding issue is
one which is very difficult to get metrics on. Ideas on how to make this
decision would be welcomed.

There is rough consensus on the following points:

- The UA should be as similar to Fennec as possible
- The UA should not differentiate between the B2G in-built browser app
  and WebRT (I believe this is now true)
- We should say "Gonk" (the platform) and not "B2G", because B2G may
  some day run on top of some other OS base

Here are three user agents:

UA1: Mozilla/5.0 (Android; Mobile; rv:12.0) Gecko/12.0 Firefox/12.0
(Current shipping Native Fennec)

UA2: Mozilla/5.0 (Gonk; Mobile; rv:12.0) Gecko/12.0 Firefox/12.0
(Pure Gonk version)

UA3: Mozilla/5.0 (Gonk, like Android; Mobile; rv:12.0) Gecko/12.0
Firefox/12.0
(Spoofing version)

There are stats:
https://bugzilla.mozilla.org/show_bug.cgi?id=761873
which show that UA1 gives us markup closest to the stock Android
browser, with UA3 close behind, and UA2 (the one without the word
"Android") trailing by some distance - suggesting it more often gets
desktop sites. So that would seem to make UA3 (the more truthful of the
two) the obvious choice from a compatibility perspective.

However, the difficulty is this. Henri Sivonen makes the following point:

> I think the strongest argument for not saying "Android" at all in the
> UA string for B2G would be avoiding sites showing prompts saying
> "Please move off the Web and install our Android app instead!"

When using my phone to browse the web, I've seen such prompts reasonably
often. They are very irritating, even when I'm on Android and so it's
possible to install the app. How much more irritating would they be if
they appeared on B2G? I'm willing to bet that most of them are shown
based on a grep of the UA string for "Android". Telling sites not to
search for "Android" when looking for Android will be a hard sell.

It's not easily possible to tell by grepping the web exactly how common
this practice is. Nor is it possible to put a number on the negative
impact it will have on the B2G user experience. That makes making a
data-driven decision difficult.

We are torn between two different types of suckage:

1) The suckage of getting desktop (or perhaps sometimes even WAP) sites
instead of mobile ones, and having to evangelise sites to send the right
thing based on the "Mobile" token rather than the "Android" token.

2) The suckage of getting "install our Android app!" prompts on our
non-Android, Open Web OS, and having to evangelise sites to search for
"Android " instead of "Android" when displaying them.

How do we decide which is less bad?

Gerv
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Gervase Markham
On 19/06/12 10:30, Gervase Markham wrote:
> When using my phone to browse the web, I've seen such prompts reasonably
> often. They are very irritating, even when I'm on Android and so it's
> possible to install the app. How much more irritating would they be if
> they appeared on B2G? I'm willing to bet that most of them are shown
> based on a grep of the UA string for "Android". Telling sites not to
> search for "Android" when looking for Android will be a hard sell.

Amusing example from today's Planet Mozilla of exactly the sort of code
which will cause problems:

http://www.misfitgeek.com/2012/06/support-firefox-mobile-add-this-code-to-your-site-or-blog/

So on B2G, we would get "Install Firefox Mobile!" with a link to the
Android version. Which would confuse the heck out of anyone who thought
they were already using Firefox Mobile on B2G (if that's what we end up
calling the browser).

Gerv

_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Dao-6
In reply to this post by Gervase Markham
On 19.06.2012 11:30, Gervase Markham wrote:
> - We should say "Gonk" (the platform) and not "B2G", because B2G may
>    some day run on top of some other OS base

Why is this a problem for a platform without native applications? Why
expose the OS base at all?

How about cutting it down to:

UA1: Mozilla/5.0 (Android; Mobile; rv:12.0) Gecko/12.0 Firefox/12.0

UA2: Mozilla/5.0 (Mobile; rv:12.0) Gecko/12.0 Firefox/12.0

> We are torn between two different types of suckage:
>
> 1) The suckage of getting desktop (or perhaps sometimes even WAP) sites
> instead of mobile ones, and having to evangelise sites to send the right
> thing based on the "Mobile" token rather than the "Android" token.
>
> 2) The suckage of getting "install our Android app!" prompts on our
> non-Android, Open Web OS, and having to evangelise sites to search for
> "Android " instead of "Android" when displaying them.
>
> How do we decide which is less bad?

I suspect 1) is going to be more common than 2), but telling people to
look for "Mobile" will probably be an easier task. 2) sounds like a
fight we can't win by evangelization.
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Gervase Markham
On 19/06/12 20:00, Dao wrote:
> Why is this a problem for a platform without native applications? Why
> expose the OS base at all?

Good question. We considered eliminating it for Fennec on Android but
the compatibility hit was considered too great. If we are going to take
that hit for B2G, then yes, it's arguable we could get a win here by
eliminating the practice.

In the past, sending OS was relevant for installing applications. In an
Open Web App OS world, that reason goes away.

Gerv
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Dao-6
On 20.06.2012 12:39, Gervase Markham wrote:
> On 19/06/12 20:00, Dao wrote:
>> Why is this a problem for a platform without native applications? Why
>> expose the OS base at all?
>
> Good question. We considered eliminating it for Fennec on Android but
> the compatibility hit was considered too great. If we are going to take
> that hit for B2G, then yes, it's arguable we could get a win here by
> eliminating the practice.

Note that I was referring to "Gonk"/"B2G"... for those there's no hit
we'd have to take.
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Gijs Kruitbosch ("Hannibal")
In reply to this post by Gervase Markham
On 20/06/2012 12:39 PM, Gervase Markham wrote:

> On 19/06/12 20:00, Dao wrote:
>> Why is this a problem for a platform without native applications? Why
>> expose the OS base at all?
>
> Good question. We considered eliminating it for Fennec on Android but
> the compatibility hit was considered too great. If we are going to take
> that hit for B2G, then yes, it's arguable we could get a win here by
> eliminating the practice.
>
> In the past, sending OS was relevant for installing applications. In an
> Open Web App OS world, that reason goes away.
>
> Gerv

Don't we support installable web apps, something that's not yet possible in such
a way (to my knowledge, anyway) on Android and/or iPhone? So wouldn't that be a
reason to distinguish the platform?

Although I suppose that in principle, Android and iPhone could very well support
installable web apps even though they don't now, and so we should perhaps not
really be aiming for that to be a key difference...

Gijs
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Gervase Markham
On 20/06/12 15:49, Gijs Kruitbosch wrote:
> Don't we support installable web apps, something that's not yet possible
> in such a way (to my knowledge, anyway) on Android and/or iPhone? So
> wouldn't that be a reason to distinguish the platform?

There is a separate JS API used by the web app installation system; lack
of that API makes it clear that app installation is not supported :-)

The aim is that web app installation will be supported everywhere
Firefox with WebRT is installable, which includes on Android (but we
have no plans to bring WebRT to iPhone that I know of).

Gerv
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Gervase Markham
In reply to this post by Dao-6
On 20/06/12 12:26, Dao wrote:
> Note that I was referring to "Gonk"/"B2G"... for those there's no hit
> we'd have to take.

Well yes, but there would be a hit to not putting "Android" - and if we
do put Android, we'd want to put something else as well otherwise we are
totally spoofing Android, and that's not a good position to be in from
an evangelism perspective!

Gerv

_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Wes Garland
On 20 June 2012 10:54, Gervase Markham <[hidden email]> wrote:

> Well yes, but there would be a hit to not putting "Android" - and if we
> do put Android, we'd want to put something else as well otherwise we are
> totally spoofing Android, and that's not a good position to be in from
> an evangelism perspective!
>

It is my belief that every time a browser maker lies in the UA that they
are damaging the web in the long-term to improve their own prospects in the
short term.

For Mozilla to do so would strike me as a being in direct conflict with The
Mission.

Wes

--
Wesley W. Garland
Director, Product Development
PageMail, Inc.
+1 613 542 2787 x 102
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

John Jensen-5
In reply to this post by Gervase Markham
Hi all,

I was asked to resurface this thread by pointing out some updated
quantitative data I have posted in the ticket associated with this
issue, https://bugzilla.mozilla.org/show_bug.cgi?id=761873.

By using a methodology that uses difflib to compare the HTML sent by the
top 17,000 or so global websites when using different UA strings. If we
make the (not entirely unproblematic) assumption that the content sent
to Android and iPhone UA strings is much more likely to actually be
designed for mobile browsers, then we can see whether various Fennec and
B2G UA strings get similar content.

See the ticket above for more detail, but based on those assumptions,
the UA strings that were most likely to receive content similar to that
sent to the iPhone or Android browser were:

1) 'Mozilla/5.0 (Android; Mobile; rv:12.0) Gecko/12.0 Firefox/12.0'
     -- this is the Fennec for Android UA
2) 'Mozilla/5.0 (Gonk, like iPhone; Mobile; rv:12.0) Gecko/12.0
Firefox/12.0'
3) 'Mozilla/5.0 (Gonk, like Android; Mobile; rv:12.0) Gecko/12.0
Firefox/12.0'

Other UA strings, that did not include a "like Android/iPhone" clause,
scored considerably lower -- see the ticket for details.

John



On 6/20/2012 7:53 AM, Gervase Markham wrote:

> On 20/06/12 15:49, Gijs Kruitbosch wrote:
>> Don't we support installable web apps, something that's not yet possible
>> in such a way (to my knowledge, anyway) on Android and/or iPhone? So
>> wouldn't that be a reason to distinguish the platform?
>
> There is a separate JS API used by the web app installation system; lack
> of that API makes it clear that app installation is not supported :-)
>
> The aim is that web app installation will be supported everywhere
> Firefox with WebRT is installable, which includes on Android (but we
> have no plans to bring WebRT to iPhone that I know of).
>
> Gerv
> _______________________________________________
> dev-planning mailing list
> [hidden email]
> https://lists.mozilla.org/listinfo/dev-planning
>


--
John Jensen
Platform Product Strategist
Mozilla Corporation
+1 650 903 0800 x831
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: B2G User Agent

Kevin Brosnan-2
On Thu 19 Jul 2012 02:13:32 PM PDT, John Jensen wrote:

> Hi all,
>
> I was asked to resurface this thread by pointing out some updated
> quantitative data I have posted in the ticket associated with this
> issue, https://bugzilla.mozilla.org/show_bug.cgi?id=761873.
>
> By using a methodology that uses difflib to compare the HTML sent by
> the top 17,000 or so global websites when using different UA strings.
> If we make the (not entirely unproblematic) assumption that the
> content sent to Android and iPhone UA strings is much more likely to
> actually be designed for mobile browsers, then we can see whether
> various Fennec and B2G UA strings get similar content.
>
> See the ticket above for more detail, but based on those assumptions,
> the UA strings that were most likely to receive content similar to
> that sent to the iPhone or Android browser were:
>
> 1) 'Mozilla/5.0 (Android; Mobile; rv:12.0) Gecko/12.0 Firefox/12.0'
>     -- this is the Fennec for Android UA
> 2) 'Mozilla/5.0 (Gonk, like iPhone; Mobile; rv:12.0) Gecko/12.0
> Firefox/12.0'
> 3) 'Mozilla/5.0 (Gonk, like Android; Mobile; rv:12.0) Gecko/12.0
> Firefox/12.0'
>
> Other UA strings, that did not include a "like Android/iPhone" clause,
> scored considerably lower -- see the ticket for details.
>
> John
>
>
>
> On 6/20/2012 7:53 AM, Gervase Markham wrote:
>> On 20/06/12 15:49, Gijs Kruitbosch wrote:
>>> Don't we support installable web apps, something that's not yet
>>> possible
>>> in such a way (to my knowledge, anyway) on Android and/or iPhone? So
>>> wouldn't that be a reason to distinguish the platform?
>>
>> There is a separate JS API used by the web app installation system; lack
>> of that API makes it clear that app installation is not supported :-)
>>
>> The aim is that web app installation will be supported everywhere
>> Firefox with WebRT is installable, which includes on Android (but we
>> have no plans to bring WebRT to iPhone that I know of).
>>
>> Gerv
>> _______________________________________________
>> dev-planning mailing list
>> [hidden email]
>> https://lists.mozilla.org/listinfo/dev-planning
>>
>
>

Getting a device to Ottawa from the US will likely incur some sort of
customs fees. The options I see are for you to place an order via a bug
or I can courier a device to Aaron during the mobile team week in
mid-August and he can send you the device once he is back in Canada.

Kevin
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning