fix(perf): move useOnyx call up the tree on LHN#64076
Conversation
|
Looking for a solution to #63811 now. |
|
Opening for review, done with testing under #63811 (comment) |
|
🚧 @mountiny has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! 🧪🧪
|
|
@adhorodyski asked for the restest but please add the test steps to the pr body |
|
Just updated, sorry! I figured we can use the same steps as one of @TMisiukiewicz's recent PR. |
|
Backlinking, it's no longer reproducible by the QA team: #63811 (comment) |
|
@brunovjk can you please complete the review and testing? thanks! |
|
Sure :D |
|
I can still reproduce this bug in our PR @adhorodyski: Screen.Recording.2025-06-13.at.13.01.18.mov |
|
Huh that's tricky then, I'll rerun it way more times now and see what's the dependency there. It was just fine this morning for 3-4 tries. |
|
iOS: https://github.com/user-attachments/assets/4bffa0a4-5cea-4e0e-addb-f93aa7dbdbf2 Android: https://github.com/user-attachments/assets/72e3feb2-d459-4b24-9e77-2684ef1dbc28 Cannot reproduce now on iOS, doing Web next. Update: Android is working fine. |
|
@brunovjk managed to fix this here, updated the PR. Can I ask you for a retest, also from the performance standpoint? Looks like I had to add one render back. For some reason it was only a wide layout problem - worked fine even on the narrow web. |
|
Very good @adhorodyski we fixed the bug. I compared our PR with the app in production and everything is consistent, but there are two details:
MacOS: Chrome / Safari - This PRScreen.Recording.2025-06-17.at.13.26.12.mov
MacOS: Chrome / Safari - This PRour_PR.movMacOS: Chrome / Safari - Productionprod.movHowever, both are also reproducible in the app in production, so I believe we are good to go here. I will continue testing on the other platforms and complete the checklist. What do you think @adhorodyski? Thanks. |
|
This looks good! I'll also restest this myself today from React's performance perspective. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb Chrome64076_android_web.moviOS: HybridApp64076_ios_native.moviOS: mWeb Safari64076_ios_web.movMacOS: Chrome / Safari64076_web_chrome.movMacOS: Desktop |
brunovjk
left a comment
There was a problem hiding this comment.
I tested this PR alongside new.expensify.com, and everything appears consistent to me. However, I noticed that the following bugs are reproducible in both versions:
-
The tooltip in the Concierge chat does not appear immediately when logging in with a new account:
MacOS: Chrome / Safari
Screen.Recording.2025-06-18.at.11.48.02.mov
-
A 1:1 chat with a completed task will disappear from the LHN when switching from "Focus Mode" back to "Most Recent" mode:
MacOS: Chrome / Safari
Screen.Recording.2025-06-18.at.11.51.35.mov
Correct me if I’m wrong, but this PR is intended to improve performance only, without changing any existing app functionality. Maybe we should update the “Test Steps” here accordingly, so that the QA team doesn't get confused with the existing bugs. What do you think @adhorodyski?
|
Yup, I think I got them wrong in the first place. cc @TMisiukiewicz I'll remove these mentioned steps now. |
|
@brunovjk those bugs you found, if that is present on main, can you please raise them in bugs channel? Or where did the expected behaviour come from? |
mountiny
left a comment
There was a problem hiding this comment.
Same as last time with one additional commit, looks good to me
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.1.69-0 🚀
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.1.69-0 🚀
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.1.69-0 🚀
|
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.1.69-3 🚀
|
@mountiny
Explanation of Change
This PR moves useOnyx connections from within render items of LHN up the tree to the list level. This lets the CPU breathe more while maintaining the very same behaviour and data.
A reattempt after #63362 got reverted.
Fixed Issues
$ #63439
PROPOSAL: N/A
Tests
Offline tests
QA Steps
In addition, QA steps from this deploy blocker apply: #63811
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop