Skip to content

[HOLD for payment 2022-12-27] White screen appears when loading chat, after being redirected from IOU modal #13074

Closed

Description

@kavimuru

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Action Performed:

  1. Have an account with some good number of chats between accounts A and B
  2. From account A, go to any other chat except B
  3. Signout from A
  4. Sign in into A again
  5. From + button, Request Money from B
  6. 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:

loading.bug.mov
Recording.1019.mp4

Expensify/Expensify Issue URL:
Issue reported by: @MonilBhavsar
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1669293337450379

View all open jobs on GitHub

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Nov 28, 2022
  2. melvin-bot commented on Nov 28, 2022

    @melvin-bot

    Triggered auto assignment to @maddylewis (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

  3. maddylewis commented on Nov 28, 2022

    @maddylewis
    Contributor

    Managing a BUG issue

    From  this  SO: https://stackoverflow.com/c/expensify/questions/14418


    • Confirm the "bug" is actually a  bug
    • 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
  4. self-assigned this
    on Nov 28, 2022
  5. added
    InternalRequires API changes or must be handled by Expensify staff
    on Nov 28, 2022
  6. MonilBhavsar commented on Nov 29, 2022

    @MonilBhavsar
    Contributor

    @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.

  7. yuwenmemon commented on Nov 29, 2022

    @yuwenmemon
    Contributor

    @MonilBhavsar do you have a link to the past issue?

  8. MonilBhavsar commented on Nov 29, 2022

    @MonilBhavsar
    Contributor

    Here is the issue #11471
    We decided to create a new issue to fix the root cause.

  9. yuwenmemon commented on Nov 30, 2022

    @yuwenmemon
    Contributor

    Lol - trying to reproduce this I think I found a different bug on dev:
    Screenshot 2022-11-30 at 11 49 52 AM

  10. yuwenmemon commented on Nov 30, 2022

    @yuwenmemon
    Contributor

    Commented in the PR here: #12960 (comment)

  11. yuwenmemon commented on Dec 1, 2022

    @yuwenmemon
    Contributor

    @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?

  12. yuwenmemon commented on Dec 1, 2022

    @yuwenmemon
    Contributor

    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 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:
    Screenshot 2022-12-01 at 2 14 18 PM

    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:
    Screenshot 2022-12-01 at 2 14 54 PM

  13. yuwenmemon commented on Dec 1, 2022

    @yuwenmemon
    Contributor

    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.

  14. 8 remaining items

  15. yuwenmemon commented on Dec 13, 2022

    @yuwenmemon
    Contributor

    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.

  16. marcaaron commented on Dec 15, 2022

    @marcaaron
    Contributor

    Hey @yuwenmemon sorry, I didn't get to reply or look at this today. Lmk if you still need help!

  17. yuwenmemon commented on Dec 15, 2022

    @yuwenmemon
    Contributor

    Nope, all good! Have a PR up if you're interested but that's it.

  18. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Dec 20, 2022
  19. 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
  20. melvin-bot commented on Dec 20, 2022

    @melvin-bot

    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:

    • External issue reporter
    • Contributor that fixed the issue
    • Contributor+ that helped on the issue and/or PR

    As a reminder, here are the bonuses/penalties that should be applied for any External issue:

    • Merged PR within 3 business days of assignment - 50% bonus
    • Merged PR more than 9 business days after assignment - 50% penalty
  21. melvin-bot commented on Dec 20, 2022

    @melvin-bot

    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:
  22. yuwenmemon commented on Dec 20, 2022

    @yuwenmemon
    Contributor

    @maddylewis I believe this was all internal - is anyone getting paid for this in reality?

  23. maddylewis commented on Dec 22, 2022

    @maddylewis
    Contributor

    hm, if it was all handled internally, then no.

  24. yuwenmemon commented on Dec 22, 2022

    @yuwenmemon
    Contributor

    Cool so then I think we can close this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.InternalRequires API changes or must be handled by Expensify staffReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions