Collect Locale attributes#2797
Merged
Merged
Conversation
jonathanmos
force-pushed
the
jmoskovich/update-rumschema
branch
from
July 23, 2025 15:05
ceb2a28 to
fbd5b1b
Compare
jonathanmos
force-pushed
the
jmoskovich/rum-9471/locale-attributes
branch
from
July 23, 2025 15:06
7065056 to
4c3a387
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #2797 +/- ##
===========================================
+ Coverage 69.84% 69.92% +0.07%
===========================================
Files 831 832 +1
Lines 31138 31191 +53
Branches 5234 5242 +8
===========================================
+ Hits 21748 21808 +60
+ Misses 7913 7908 -5
+ Partials 1477 1475 -2
🚀 New features to boost your workflow:
|
jonathanmos
force-pushed
the
jmoskovich/rum-9471/locale-attributes
branch
from
July 23, 2025 15:44
4c3a387 to
c5dd9a9
Compare
Closed
jonathanmos
force-pushed
the
jmoskovich/rum-9471/locale-attributes
branch
from
July 24, 2025 11:54
c5dd9a9 to
59a61cb
Compare
jonathanmos
force-pushed
the
jmoskovich/rum-9471/locale-attributes
branch
from
July 24, 2025 12:15
59a61cb to
6182a2d
Compare
jonathanmos
marked this pull request as ready for review
July 24, 2025 13:23
| * @property timeZone The device’s current time zone identifier, e.g. 'Europe/Berlin'. | ||
| */ | ||
| data class LocaleInfo( | ||
| val locales: List<String>, |
Contributor
There was a problem hiding this comment.
do elements of locales have the same meaning as currentLocale? Can es-FR be in locales?
Member
Author
There was a problem hiding this comment.
yes, locales is an array of the currently set values in the same format. For example:
["en-US", "he-IL"]
aleksandr-gringauz
approved these changes
Jul 28, 2025
ambushwork
approved these changes
Jul 28, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Collects the following Locale attributes:
currentLocale - the current locale defined for the user or falls back to the device default
locales - an ordered list of locales the user has defined
timeZone - the timeZone of the device
These new attributes are sent within the view, error, action and resource scopes within the application and device categories. A known edge case at the moment is that if the user updates the values of locale or timezone while the sdk is running this change will not be reflected in what we send - the values are set at the time that the context is created and cached. This means that only a restart of the SDK would send updated values. However, users don't often change their timezone or locale settings so this may be an acceptable limitation. The alternative could be to set broadcast receivers for these changes, but that may be overkill.
Motivation
Part of the initiative to collect additional attributes.
Additional Notes
Anything else we should know when reviewing?
Review checklist (to be filled by reviewers)