-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A lot of tablets flagged as phones #1528
Comments
I have a PR for this coming soon, just doing some comparison tests. |
I wanted to bring up a change I'm making in response to this issue, and log some of my findings. As I was adding devices for these UAs, I realized that we can change some browsers to detect a mobile phone vs. a tablet (really it's "not a mobile phone", but in most cases this means it's a tablet) by looking for the presence of the "Mobile" keyword in the UA. In the list of UAs above, only one has the "Mobile" keyword, and it's on the Samsung SM-T111 which is one of those devices that straddle the border between a Phone and a Tablet (Phablet, Fonepad, etc...). http://www.amazon.in/Samsung-Galaxy-Tab-Neo-T111/dp/B00O1R0LES It's also on UC Browser, which I haven't explored yet (and wasn't planning on making this change to, yet). For Chrome, Google's site explicitly states that tablets won't have the "Mobile" keyword:
https://developer.chrome.com/multidevice/user-agent I was curious if this change could be made to Android Browser and Android Webview as well, so I grabbed all of the UAs we've seen for those two browsers this year. I removed any that were browsers that were either mis-detected by Browscap (to be fixed later) or were for browsers that Browscap doesn't detect yet and ran them through my changes, further filtering out only the ones that parsed as "general Tablet". I then ran the remaining UAs through Whichbrowser since it returns the device type pretty reliably and has good device detection. I was mainly curious which ones Whichbrowser is parsing as "mobile" (Mobile Phone) vs. which ones it parses as "tablet". Here are the results for these two browsers:
This assumes that Whichbrowser is correctly identifying the "mobile" ones, I haven't taken the time to look at each device. At a quick glance it does seem like a lot of them fall into the "Phablet" category, which might explain why they're lacking the "Mobile" keyword in the UA. Right now I was only planning to make this change to Android Browser, Android Webview, Chrome, Opera, Puffin, Yandex Browser and the new Yandex Search App that I'm adding (found in the UAs in this ticket). I selected these mainly because they're UAs from this ticket, or UAs I saw being mis-detected in some large UA lists that I pulled and did a comparison on (to Seem reasonable? Most likely this will reduce issues like this one where Tablets are being detected as Mobile, but it does have a smaller chance of Mobile devices being detected as Tablets until the device is explicitly added to the patterns. I considered making the "default" device "general Mobile Device (Touch)" instead of "general Tablet", but I'm not sure if that really helps anything. |
If this help to reduce issues, we could do this, but I prefer |
Safari based TV devices have the |
I saw some devices that whichbrowser parsed as neither mobile or tablet. They have some other types like "gaming" and "devboard". Here are some that were parsed as "television":
(no "TV" indicator other than the device name) Here are some that are parsed as "devboard":
From the limited research I've done on these, the identifiers seem to be the name of the CPU and/or SDK that the device uses, which might be good candidates for the "general Mobile Device" device. One side-effect I am seeing is that the Lite tests fail on UAs that lack the "Mobile" keyword but have a Mobile Phone as the detected device (in the full file), as these are detected as Tablets since the Lite file doesn't have most phone devices. That said, the Standard tests don't fail on these, even though they parse the device in the same way. This is due to the "Device_Type" property being excluded from the Standard tests, but not the Lite tests. |
I did the same comparison with Chrome (on Android) and came up with 12,000 out of 12,818 that whichbrowser detected as "tablet" (93%). I think I may just do it for the browsers I mentioned above, minus Android Webview (it seems less consistent there for whatever reason). |
Samsung has some guidelines on the "Mobile" keyword for the Samsung Browser: http://developer.samsung.com/internet/user-agent-string-format
|
…ile" in some browsers Fixes browscap#1528. Most of the reasoning for what I’m doing here is discussed in the issue. I’ll add some inline comments. I added the UAs from browscap#1528 that had a discernible device identifier as tests. I did end up adding the “mobile” keyword to Android Webview, because if I didn’t, the Android Browser patterns would take priority in some cases. I did run these changes against several hundred thousand real world useragents and confirmed that the only difference in parsing was the change from mobile phone to tablet for some UAs (browser parsing didn’t change except for a few cases where Puffin was correctly detected where it was being mis-detected as Chrome previously). This also adds Chrome/Chromium version 62, which is in the “Dev Channel” right now (we’ve seen a few UAs with that version already).
By using TDS tracker "bemob" i found this list of tablets:
Also browcast can't detect phone model. Maybe this is the main problem.
The text was updated successfully, but these errors were encountered: