Skip to content
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

Upgrade to latests matomo-org/device-detector version #134

Open
jmaitrehenry opened this issue Oct 22, 2021 · 9 comments
Open

Upgrade to latests matomo-org/device-detector version #134

jmaitrehenry opened this issue Oct 22, 2021 · 9 comments

Comments

@jmaitrehenry
Copy link
Contributor

jmaitrehenry commented Oct 22, 2021

It's would be a great move to update this lib to the latest version of matomo-org/device-detector (v4.3.1).

This should fix issues:

@etienne-martin
Copy link
Owner

I just released version 3 with your recent upgrade but it doesn't seem like it fixed #129.

I updated the demo to the latest version and tried with a Chromecast user-agent and it gets detected as Chrome Webview.

@jmaitrehenry
Copy link
Contributor Author

Exactly, we updated the up to 4.1.0, we need to continue the upgrade to 4.3.1.
I will try to do it next week

@Findus23
Copy link

Just FYI @etienne-martin, @jmaitrehenry:

In case you want to easily test if an issue is also on the upstream php device-detector, you can use my site here:
https://devicedetector.lw1.at

It should always return the detection results from the latest master branch of https://github.com/matomo-org/device-detector.
So if the output there is wrong, then it's a bug in upstream.

@etienne-martin
Copy link
Owner

Great, thanks @Findus23

@dseeker
Copy link

dseeker commented Dec 22, 2021

I'm having problems with latest FireTV 4k Max detected as a phone, seems the latest version has a fix for it, is this close to release?

@etienne-martin
Copy link
Owner

Are you getting the correct result when using this site https://devicedetector.lw1.at ?

@dseeker
Copy link

dseeker commented Dec 22, 2021

no, I've copied the Amazon Fire TV 4k max user agent from the web app and using an emulator it's detected as a phone
image

here's the commit that fixes this issue which many of our customers are complaining about
matomo-org/device-detector@5d1fa40

here's the user agent so you can test (edited, corrected)
Mozilla/5.0 (Linux; Android 9; AFTKA Build/PS7255; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/94.0.4606.118 Mobile Safari/537.36 cordova-amazon-fireos/3.4.0 AmazonWebAppPlatform/3.4.0;2.0

@etienne-martin
Copy link
Owner

The latest version of matomo works fine with this user-agent:

Gibbon/2020.2.2.0/2020.2.2.0: Netflix/2020.2.2.0 (DEVTYPE=NFANDROID2-PRV-FIRETVSTICK2018; CERTVER=0)

Found it in their test fixture.

I haven't looked at the new regex introduced by matomo-org/device-detector@5d1fa40 to see what could cause yours to fail.

Even if we were to update the library with what's currently upstream, the user-agent you provided would still fail so you can report the issue at https://github.com/matomo-org/device-detector/issues if you think there's something wrong with the detection of that user-agent.

Once the issue is fixed upstream, we'll be able to pull these changes into the library. No guarantee that this will be done quickly however.

@sanchezzzhak
Copy link

Mozilla/5.0 (Linux; Android 9; AFTKA Build/PS7255; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/94.0.4606.118 Mobile Safari/537.36 cordova-amazon-fireos/3.4.0 AmazonWebAppPlatform/3.4.0;2.0
added to matomo-org/device-detector#6969

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants
@jmaitrehenry @sanchezzzhak @Findus23 @etienne-martin @dseeker and others