Skip to content

[$500] [HOLD for payment 2023-09-27] Android - Infinite loading after opening personal details page #27560

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. Click on your avatar to open settings
  2. Click on profile
  3. Click on personal details

Expected Result:

Personal details page should be opened.

Actual Result:

Can't open personal details page and infinite loading spinner

Workaround:

Can the user still use Expensify without this being fixed? Have you informed them of the workaround?

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android / native
  • Android / Chrome
  • iOS / native
  • iOS / Safari
  • MacOS / Chrome / Safari
  • MacOS / Desktop

Version Number: 1.3.70-5
Reproducible in staging?: y
Reproducible in production?: n
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation

XRecorder_15092023_165615.mp4
az_recorder_20230915_151359.1.mp4

Expensify/Expensify Issue URL:
Issue reported by: @Ahmed-Abdella
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1694786719105809

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01dbd77bfba87b38dc
  • Upwork Job ID: 1707718640343793664
  • Last Price Increase: 2023-09-29

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Sep 15, 2023
  2. melvin-bot commented on Sep 15, 2023

    @melvin-bot

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

  3. melvin-bot commented on Sep 15, 2023

    @melvin-bot

    Bug0 Triage Checklist (Main S/O)

    • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
    • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
      • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
    • This bug is reproducible using the reproduction steps in the OP. S/O
      • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
      • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
    • This issue is filled out as thoroughly and clearly as possible
      • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
    • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync
  4. OSBotify commented on Sep 15, 2023

    @OSBotify
    Contributor

    👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open StagingDeployCash deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

    1. Identify the pull request that introduced this issue and revert it.
    2. Find someone who can quickly fix the issue.
    3. Fix the issue yourself.
  5. melvin-bot commented on Sep 15, 2023

    @melvin-bot

    Triggered auto assignment to @Li357 (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

  6. mkhutornyi commented on Sep 16, 2023

    @mkhutornyi
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    Infinite loading when first open personal details page after updating personal details on another device

    What is the root cause of that problem?

    Clear repro step:

    1. Login any account on device A
    2. On device B, logout if already logged in
    3. On device B, login same account as in device A
    4. On device A, update any personal details. i.e. Date of birth
    5. On device B, go to Settings > Profile > Personal details page

    Let's find the root cause from above repro step.
    On first login on B, private_personalDetails has no data in Onyx.
    But after updating dob in A, B receives pusher event and Onyx data is updated to {dob: 'xxxx-xx-xx}
    PersonalDetailsInitialPage uses usePrivatePersonalDetails hook to get personal details data from api.
    The issue is in that hook.

    useEffect(() => {
    if (isOffline || Boolean(PersonalDetails.getPrivatePersonalDetails())) {
    return;
    }
    PersonalDetails.openPersonalDetailsPage();
    }, [isOffline]);

    {dob: 'xxxx-xx-xx} meets Boolean(PersonalDetails.getPrivatePersonalDetails()) so early returned.

    So even though local data is not complete (not yet fetched from api), api is never called, so isLoading key never exists which makes this condition always true:

    const isLoadingPersonalDetails = lodashGet(props.privatePersonalDetails, 'isLoading', true);

    What changes do you think we should make in order to solve the problem?

    One api is called, isLoading value is added to private_personalDetails, so I think this key existence should be enough to check if personal details is fetched or not

    if (isOffline || Boolean(PersonalDetails.getPrivatePersonalDetails())) {

    So update this condition to:

    const data = PersonalDetails.getPrivatePersonalDetails();
     if (isOffline || Boolean(data) && data.isLoading !== undefined) { 
    

    What alternative solutions did you explore? (Optional)

    We may use another key instead of isLoading

  7. Li357 commented on Sep 18, 2023

    @Li357
    Contributor

    Able to reproduce on Web as well via @mkhutornyi's repro steps. RCA is good and proposal looks good. Since this is a deploy blocker, unless we can raise a PR within the hour we might handle this internally.

  8. mkhutornyi commented on Sep 18, 2023

    @mkhutornyi
    Contributor

    @Li357 I can raise PR right now

  9. 42 remaining items

  10. CortneyOfstad commented on Oct 3, 2023

    @CortneyOfstad
    Contributor

    @Li357 bump on the above ^^^^

  11. CortneyOfstad commented on Oct 5, 2023

    @CortneyOfstad
    Contributor

    @Li357 bump again

  12. Li357 commented on Oct 6, 2023

    @Li357
    Contributor

    Sorry about the delay! If I'm interpreting this SO right, that should be correct.

  13. CortneyOfstad commented on Oct 6, 2023

    @CortneyOfstad
    Contributor

    Thanks @Li357!

    @Ahmed-Abdella — can you link me your Upwork profile? I'm having trouble finding it and I want to make sure that I am sending the proposal to the correct individual. Thank you!

    @mkhutornyi — same as above. I want to make sure I am sending the proposal to the correct individual as there are two "Mykhailo K." entries in Upwork.

    Thanks!

  14. mkhutornyi commented on Oct 6, 2023

    @mkhutornyi
    Contributor

    @CortneyOfstad I am the one whom you just paid in #26243 🙂

  15. Ahmed-Abdella commented on Oct 6, 2023

    @Ahmed-Abdella
    Contributor
  16. CortneyOfstad commented on Oct 6, 2023

    @CortneyOfstad
    Contributor

    I am the one whom you just paid in #26243 🙂

    For some reason that one had your hiring profile listed automatically, but not this one 🤔 So weird! Thanks @mkhutornyi and send over the proposal!

    @Ahmed-Abdella Also sent over your proposal! Let me know when these are accepted and I'll get them paid ASAP 👍

  17. Ahmed-Abdella commented on Oct 6, 2023

    @Ahmed-Abdella
    Contributor

    @CortneyOfstad I accepted the offer, Thanks!

  18. CortneyOfstad commented on Oct 6, 2023

    @CortneyOfstad
    Contributor

    Both have been paid!

    @Li357 and @mkhutornyi where are we at with the checklist above? Thanks!

  19. mkhutornyi commented on Oct 6, 2023

    @mkhutornyi
    Contributor

    I can help filling checklist.

    Regression Test Proposal

    1. Login any account on device A
    2. On device B, logout if already logged in
    3. On device B, login same account as in device A
    4. On device A, update any personal details. i.e. Date of birth
    5. On device B, go to Settings > Profile > Personal details page
    6. Verify that page fully shows after full screen loading indicator, not stuck at loading
  20. CortneyOfstad commented on Oct 9, 2023

    @CortneyOfstad
    Contributor
  21. CortneyOfstad commented on Oct 9, 2023

    @CortneyOfstad
    Contributor

    Thanks all! Closing!

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.DailyKSv2EngineeringExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions