You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[$250] App does not update message timestamps immediately after changing device timezone #68715
BugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributors
Version Number: v9.1.96-1 Reproducible in staging?: Yes Reproducible in production?: Yes If this was caught during regression testing, add the test name, ID and link from TestRail:#68001 Email or phone of affected tester (no customers):applausetester+dp312@applause.expensifail.com Issue reported by: Applause Internal Team Device used: Mac / Safari App Component: Other
Action Performed:
Set device time to Automatic.
Open the app and send a message. Observe the timestamp (matches device settings).
Change device time to Manual and set a different timezone (e.g., Madrid).
Return to the app.
Observe the timestamp of previously sent messages.
Send a new message in the same chat.
Send a new message in another chat.
Observe timestamps of new messages.
Refresh the page/app.
Expected Result:
Timestamps should update to reflect the new device timezone immediately (both for old and new messages), without requiring a manual refresh.
Actual Result:
Old messages keep the previous timezone until the app is refreshed.
New messages also display the old timezone until refresh.
After refreshing, timestamps update correctly.
changed the title [-]App does not update message timestamps immediately after changing device timezone[/-][+][$250] App does not update message timestamps immediately after changing device timezone[/+]on Aug 19, 2025
Please re-state the problem that we are trying to solve in this issue.
App does not update message timestamps immediately after changing device timezone
What is the root cause of that problem?
I believe the root cause is that the app does not listen to onFocus changes.
The only registered events are mousemove, touchstart, keydown, scroll
What changes do you think we should make in order to solve the problem?
My proposal is to add visibilitychange event listener to the update date handler. It is supported by all the browsers as you can see from this link.
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future
Write tests to avoid regression. These test would check if the visibilitychange event is triggered and change in timezone changes the app time in realtime.
What alternative solutions did you explore? (Optional)
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
This is a pretty niche bug. IMO, checking and setting timezone on app start alone is enough. A normal user would rarely change the timezone their own. But if we still want to fix this, we could go with @nabi-ebrahimiproposal.
BugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributors
Activity
melvin-bot commentedon Aug 19, 2025
Triggered auto assignment to @jliexpensify (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.[-]App does not update message timestamps immediately after changing device timezone[/-][+][$250] App does not update message timestamps immediately after changing device timezone[/+]melvin-bot commentedon Aug 19, 2025
Job added to Upwork: https://www.upwork.com/jobs/~021957689789412016624
melvin-bot commentedon Aug 19, 2025
Triggered auto assignment to Contributor-plus team member for initial proposal review - @dominictb (
External)nabi-ebrahimi commentedon Aug 19, 2025
🚨 Edited by proposal-police: This proposal was edited at 2025-08-19 07:15:40 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
App does not update message timestamps immediately after changing device timezone
What is the root cause of that problem?
We only update the selected timestamp on page refresh.
App/src/libs/Navigation/AppNavigator/AuthScreens.tsx
Lines 145 to 164 in d1b5bdd
Then we don't subscribe to device timezone changes when it is set to automatic.
What changes do you think we should make in order to solve the problem?
We can subscribe to the device's
timezoneand update the selected timezone inpersonalDetailsListinOnyxwhen it is set to automatic.On the web,
react-native-localizedoes not work. We can check the timezone on App Focus/ResumeWhat specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
None
What alternative solutions did you explore? (Optional)
Instead of
react-native-localize, we can listen to app state change and update the timezone if needed.dominictb commentedon Aug 19, 2025
@nabi-ebrahimi Can you elaborate the web case and share a test branch? I don't like the periodical check idea.
nabi-ebrahimi commentedon Aug 19, 2025
@dominictb thanks for the review, this is the test branch
ben-mathu commentedon Aug 19, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
App does not update message timestamps immediately after changing device timezone
What is the root cause of that problem?
I believe the root cause is that the app does not listen to onFocus changes.
The only registered events are
mousemove,touchstart,keydown,scrollWhat changes do you think we should make in order to solve the problem?
My proposal is to add
visibilitychangeevent listener to the update date handler. It is supported by all the browsers as you can see from this link.What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future
Write tests to avoid regression. These test would check if the
visibilitychangeevent is triggered and change in timezone changes the app time in realtime.What alternative solutions did you explore? (Optional)
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
dominictb commentedon Aug 22, 2025
This is a pretty niche bug. IMO, checking and setting timezone on app start alone is enough. A normal user would rarely change the timezone their own. But if we still want to fix this, we could go with @nabi-ebrahimi proposal.
Note for @nabi-ebrahimi:
window'sfocusevent.Visibility.onVisibilityChangeinsteadC+ reviewed 🎀👀🎀
15 remaining items
melvin-bot commentedon Sep 2, 2025
@jliexpensify Still overdue 6 days?! Let's take care of this!
melvin-bot commentedon Sep 9, 2025
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
melvin-bot commentedon Sep 9, 2025
@jliexpensify 6 days overdue. This is scarier than being forced to listen to Vogon poetry!
jliexpensify commentedon Sep 9, 2025
@neil-marcellini should we close this if it's not worth fixing?
melvin-bot commentedon Sep 12, 2025
@jliexpensify Whoops! This issue is 2 days overdue. Let's get this updated quick!
jliexpensify commentedon Sep 14, 2025
Bump @neil-marcellini can we close this?
melvin-bot commentedon Sep 16, 2025
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
melvin-bot commentedon Sep 16, 2025
@neil-marcellini @jliexpensify @dominictb this issue is now 4 weeks old, please consider:
Thanks!
jliexpensify commentedon Sep 16, 2025
Chatted to Neil via DM's, lets close this.