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

Platform reports iOS while running on macOS #31

Open
AvdLee opened this issue Apr 12, 2023 · 1 comment
Open

Platform reports iOS while running on macOS #31

AvdLee opened this issue Apr 12, 2023 · 1 comment

Comments

@AvdLee
Copy link

AvdLee commented Apr 12, 2023

See this line of code: https://github.com/amplitude/experiment-ios-client/blob/main/Sources/Experiment/DefaultUserProvider.swift#L54

When using the SDK on macOS, I would expect this value to be macOS.
The Amplitude SDK seems to do this differently, since our analytics still show users for macOS. However, variants are fetched using iOS instead:

[Experiment] Fetch variants for user: ["platform": "iOS", "version": "2.0.0", "user_id": "XXX", "language": "English", "os": "ios 13.3.1.", "device_id": "XXX", "device_manufacturer": "Apple", "device_model": "arm64", "library": "experiment-ios-client/1.9.0"]

Note the value for os being ios 13.3.1.: the macOS version is correct, but it's prefixed with iOS instead of macOS. Due to this, our experiment didn't work as we were targeting macOS users.

@bgiori
Copy link
Collaborator

bgiori commented Apr 23, 2023

Thanks for this report @AvdLee.

I'll add a ticket for updating this currently hardcoded field

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

2 participants