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

[Redesign] Switch Android client ID source. #878

Merged
merged 1 commit into from
Sep 14, 2024

Conversation

Komodo5197
Copy link

It seems like the id in the androidDeviceInfo.id is actually a build ID. I've switched to an ID provided by the app_set_id plugin, which I believe should be unique.

@Chaphasilor
Copy link
Collaborator

Hmm, thanks for attempting to fix this. I'll give it a try later, but my guess is this won't solve the issue. The ID seems to rely on Play Store metadata (which is bad for F-Droid releases), and will be the same for all apps published by the same dev, on Android at least.
On iOS at least the value seems to be unique per-device, but that would still prevent installing different versions on one device.

I believe a random but stable ID should work. We could generate it and store it to the DB on first start.

@Chaphasilor
Copy link
Collaborator

Chaphasilor commented Sep 13, 2024

Okay, just tested it and it has the same issue, at least when using two versions of the app on the same device. Should we just use a random string, like finamp-xyzabc?
see correction below

@Chaphasilor
Copy link
Collaborator

I just noticed I didn't check out the correct branch. Let me take another look 😅

@Komodo5197
Copy link
Author

Generating and storing a random ID would be my next thought too. I'll switch to that if this take doesn't work out.

@Chaphasilor
Copy link
Collaborator

Okay, it seems like it actually worked. Same device, different package ID. It could be that a different device but the same package ID won't work, but I can't test that since my other phone died. So I'll merge it for now, and we'll see if anyone complains.

I think the IDs/names should stay the same in Jellyfin too, since the access token is already generated. So there shouldn't be any issues with users getting logged out.
Thanks for the fix!

@Chaphasilor Chaphasilor merged commit 2769c4d into jmshrv:redesign Sep 14, 2024
4 checks passed
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

Successfully merging this pull request may close these issues.

2 participants