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
[HOLD for payment 2022-12-27] White screen appears when loading chat, after being redirected from IOU modal #13074
Have an account with some good number of chats between accounts A and B
From account A, go to any other chat except B
Signout from A
Sign in into A again
From + button, Request Money from B
In the chat view with B, white screen appears while chats are loading
Expected Result:
Skeleton view should appear
Actual Result:
White screen appears
Workaround:
unknown
Platform:
Where is this issue occurring?
Web
iOS
Android
Desktop App
Mobile Web
Version Number: 1.2.32-1 Reproducible in staging?: y Reproducible in production?: n Email or phone of affected tester (no customers): Logs:https://stackoverflow.com/c/expensify/questions/4856 Notes/Photos/Videos:
Confirm the bug is not a duplicate report of an existing GH (close the GH and add any relevant details to the original GH )
The bug is reproducible
If you’re unable to reproduce the bug:
Add the Needs reproduction label
Comment on the issue outlining the steps you took to reproduce the bug, and your results
Tag the issue reporter and the Applause QA member who created the issue. Ask them to clarify the reproduction steps and/or to check the reproduction steps again.
If the bug is reproducible:
The GH is filled out as clearly as possible -- this means the GH body and title are clear
The GH was created by a QA tester or an Expensify Employee
If the bug is related to OldDot you should decide whether it is widespread enough to justify fixing or it is better to wait for reunification. If it’s better to wait, close the GH and provide details
If there's a link to Slack, check the discussion and see why we decided to fix it or not
Decide if the GH should be resolved by an External contributor or an Internal engineer and add the appropriate label
@yuwenmemon thanks for picking this. I did some digging in the past issue. Happy to help here too and could you please assign me for a review as I'm curious about the fix.
@MonilBhavsar I wonder if the latency is the same as when we are loading the report in general? In which case would we just want to show some skeleton UI above showing that the chat messages are loading?
I guess the other solution could be to show the skeleton UI we see in the first screenshot uniformly - and show the new IOU and messages together at once?
When we load a report, we use two criteria for showing the skeleton UI: A call to the internal method isReportReadyForDisplay() and the variable isLoadingInitialReportActions which looks to make sure that the reportActions prop for the ReportScreen has items inside of it.
For the normal flow of loading the report we see these properties change like so when the reportActions are finally set in Onyx:
However, when coming from the Request Money flow, we optimistically merge the IOU reportAction into Onyx, which means that we end up setting isLoadingInitialReportActions to false, even though we haven't loaded the bulk of the actual reportActions in Onyx:
Okay, so then how to solve... @marcaaron it seems like you've been touching a lot of the logic around this the last month or so. Curious if you have any thoughts?
In an ideal world, I guess we show the skeleton UI above the optimistic IOU. But I'm a bit lost on how we can do that.
Yes, can definitely try to think of some things! Let's figure out what we want first.
@marcaaron now that we know what we want - any thoughts on where you would point me to look into first for this? I was initially thinking we would do the logic for showing the skeleton above the optimistic report action in the ReportScreen component. We'll probably have to change some of the logic around state.skeletonViewContainerHeight as well.
Although, I also realize that we also render a Skeleton deeper in the ReportActionsList as well.
changed the title [-]White screen appears when loading chat, after being redirected from IOU modal[/-][+][HOLD for payment 2022-12-27] White screen appears when loading chat, after being redirected from IOU modal[/+]on Dec 20, 2022
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.2.41-4 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@yuwenmemon] The PR that introduced the bug has been identified. Link to the PR:
[@yuwenmemon] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
[@yuwenmemon] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
[@maddylewis] A regression test has been added or updated so that the same bug will not reach production again. Link to the GH issue for creating the test here:
Activity
melvin-bot commentedon Nov 28, 2022
Triggered auto assignment to @maddylewis (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.maddylewis commentedon Nov 28, 2022
Managing a BUG issue
From this SO: https://stackoverflow.com/c/expensify/questions/14418
If you’re unable to reproduce the bug:
Needs reproductionlabelIf the bug is reproducible:
MonilBhavsar commentedon Nov 29, 2022
@yuwenmemon thanks for picking this. I did some digging in the past issue. Happy to help here too and could you please assign me for a review as I'm curious about the fix.
yuwenmemon commentedon Nov 29, 2022
@MonilBhavsar do you have a link to the past issue?
MonilBhavsar commentedon Nov 29, 2022
Here is the issue #11471
We decided to create a new issue to fix the root cause.
yuwenmemon commentedon Nov 30, 2022
Lol - trying to reproduce this I think I found a different bug on dev:

yuwenmemon commentedon Nov 30, 2022
Commented in the PR here: #12960 (comment)
yuwenmemon commentedon Dec 1, 2022
@MonilBhavsar I wonder if the latency is the same as when we are loading the report in general? In which case would we just want to show some skeleton UI above showing that the chat messages are loading?
When accessing the report fresh without coming from an IOU request:
https://user-images.githubusercontent.com/4741899/205155341-cf5ed81c-167e-4565-bc34-82bb3f4a7293.mp4
When accessing via an IOU:
https://user-images.githubusercontent.com/4741899/205155930-1cc11d36-cbfd-4c53-a28d-537d2190e27f.mp4
I guess the other solution could be to show the skeleton UI we see in the first screenshot uniformly - and show the new IOU and messages together at once?
yuwenmemon commentedon Dec 1, 2022
Yep, so here's what happens:
When we load a report, we use two criteria for showing the skeleton UI: A call to the internal method
isReportReadyForDisplay()and the variableisLoadingInitialReportActionswhich looks to make sure that thereportActionsprop for the ReportScreen has items inside of it.For the normal flow of loading the report we see these properties change like so when the

reportActionsare finally set in Onyx:However, when coming from the Request Money flow, we optimistically merge the IOU

reportActioninto Onyx, which means that we end up settingisLoadingInitialReportActionstofalse, even though we haven't loaded the bulk of the actualreportActionsin Onyx:yuwenmemon commentedon Dec 1, 2022
Okay, so then how to solve... @marcaaron it seems like you've been touching a lot of the logic around this the last month or so. Curious if you have any thoughts?
In an ideal world, I guess we show the skeleton UI above the optimistic IOU. But I'm a bit lost on how we can do that.
8 remaining items
yuwenmemon commentedon Dec 13, 2022
@marcaaron now that we know what we want - any thoughts on where you would point me to look into first for this? I was initially thinking we would do the logic for showing the skeleton above the optimistic report action in the ReportScreen component. We'll probably have to change some of the logic around
state.skeletonViewContainerHeightas well.Although, I also realize that we also render a Skeleton deeper in the ReportActionsList as well.
marcaaron commentedon Dec 15, 2022
Hey @yuwenmemon sorry, I didn't get to reply or look at this today. Lmk if you still need help!
yuwenmemon commentedon Dec 15, 2022
Nope, all good! Have a PR up if you're interested but that's it.
[-]White screen appears when loading chat, after being redirected from IOU modal[/-][+][HOLD for payment 2022-12-27] White screen appears when loading chat, after being redirected from IOU modal[/+]melvin-bot commentedon Dec 20, 2022
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.2.41-4 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2022-12-27. 🎊
After the hold period, please check if any of the following need payment for this issue, and if so check them off after paying:
As a reminder, here are the bonuses/penalties that should be applied for any External issue:
melvin-bot commentedon Dec 20, 2022
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
yuwenmemon commentedon Dec 20, 2022
@maddylewis I believe this was all internal - is anyone getting paid for this in reality?
maddylewis commentedon Dec 22, 2022
hm, if it was all handled internally, then no.
yuwenmemon commentedon Dec 22, 2022
Cool so then I think we can close this out.