Skip to content

[$500] Workspace - Endless skeleton loader on the member page if you switch to it multiple times #40595

Closed

Description

@lanitochka17

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


Version Number: 1.4.63.7
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Issue reported by: Applause - Internal Team

Action Performed:

  1. Log in with a new expensifail account
  2. Create a workspace
  3. Navigate to the members page
  4. Navigate back
  5. Navigate to the members page again and wait 20-30 seconds
  6. Navigate back
  7. Navigate to the members page again

Expected Result:

Skeleton loader should only be visible for a very short time

Actual Result:

Endless skeleton loader appears on the member page if you switch to it multiple times

Workaround:

Unknown

Platforms:

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

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6455086_1713542431121.MMUC4948.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01e843a4238c37c0d9
  • Upwork Job ID: 1781491296362684416
  • Last Price Increase: 2024-05-15

Activity

  1. melvin-bot commented on Apr 19, 2024

    @melvin-bot

    Triggered auto assignment to @puneetlath (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

  2. github-actions commented on Apr 19, 2024

    @github-actions
    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.
  3. lanitochka17 commented on Apr 19, 2024

    @lanitochka17
    Author

    @puneetlath FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

  4. lanitochka17 commented on Apr 19, 2024

    @lanitochka17
    Author

    We think that this bug might be related to #wave-collect - Release 1

  5. added
    ExternalAdded to denote the issue can be worked on by a contributor
    on Apr 20, 2024
  6. changed the title [-]Workspace - Endless skeleton loader on the member page if you switch to it multiple times[/-] [+][$250] Workspace - Endless skeleton loader on the member page if you switch to it multiple times[/+] on Apr 20, 2024
  7. melvin-bot commented on Apr 20, 2024

    @melvin-bot
  8. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Apr 20, 2024
  9. melvin-bot commented on Apr 20, 2024

    @melvin-bot

    Triggered auto assignment to Contributor-plus team member for initial proposal review - @hungvu193 (External)

  10. digitalwaver commented on Apr 20, 2024

    @digitalwaver

    Upon thorough analysis, it's evident that the endless skeleton loader arises from delays in data fetching and rendering when switching to the member page multiple times. To address this issue, I propose the following technical changes:

    1. I'll implement efficient data fetching strategies aimed at reducing latency and improving loading times. This may involve optimizing network requests, employing caching mechanisms, or exploring asynchronous data loading techniques.
    2. By revisiting the component rendering logic, I'll prioritize the display of essential content while asynchronously loading additional data in the background. This approach will mitigate the appearance of the endless skeleton loader and provide users with meaningful content promptly.
    3. I'll introduce robust error handling mechanisms to gracefully manage data retrieval failures and network interruptions. Users will be presented with informative error messages, and detailed error logs will be generated for debugging purposes.
    4. Integration of performance monitoring tools will be crucial for tracking page load times and identifying potential performance bottlenecks. Continuous monitoring will enable me to refine the member page loading experience and maintain optimal performance levels.

    I hope this solution will help you with this issue.

    Cooper Brown from Upwork.

  11. 36 remaining items

  12. hungvu193 commented on May 8, 2024

    @hungvu193
    Contributor

    and since the workspace member list cannot be empty (at least the owner is in the member list), we can show the message Cannot display the member list right now! Please try again! (this is subject to change) by modifying the getHeaderMessage function

     const getHeaderMessage = () => {
        if (isOfflineAndNoMemberDataAvailable) {
            return translate('workspace.common.mustBeOnlineToViewMembers');
        }
    
        return isEmptyObject(policy?.employeeList) ? 'Cannot display the member list right now! Please try again!': '';
    };
    

    Still can not reproduce this issue but I don't agree with you at this point, employeeList can be empty during it's fetching from server for the first time user open the app.

    Screenshot 2024-05-08 at 14 50 46

    Since this issue was not reproduced anymore, I just wonder if we can close it?

  13. dominictb commented on May 8, 2024

    @dominictb
    Contributor

    @hungvu193 the empty array value of employeeList comes from the OpenApp API, the mergeCollection for the policy_ collection operation. It's a separate issue and the BE should take a look into this?

    image

    However, if the OpenApp returns, the employeeList again cannot be empty, or at least it cannot be null unless the situation described in my proposal happens, thus my assumption is not totally inaccurate

  14. hungvu193 commented on May 8, 2024

    @hungvu193
    Contributor

    the empty array value of employeeList comes from the OpenApp API,

    I think this is intentional. So I still don't agree with you at that point.
    cc @puneetlath for your thoughts at above discussion, I think we can close this issue.

  15. melvin-bot commented on May 8, 2024

    @melvin-bot

    📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

  16. dominictb commented on May 8, 2024

    @dominictb
    Contributor

    @hungvu193 to be honest, I don't think it should be intentional that way. The onyx updates coming from the OpenApp API call should be atomic, which means FE should only care about the final state after apply all the Onyx operations at once. So, under no circumstances should the policy?.employeeList be promptly [] before becoming non-empty again, because OpenApp API call is just 1 single operation, which return the policy data with non-empty employeeList (even though it contains multiple Onyx sub-operations). @puneetlath can we have someone on the BE team to check this point, as I believe we shouldn't split into 2 operations mergeCollection and merge for policy_XXX just to update the employeeList from [] to {[email]: {....}}. It should live either in mergeCollection operation.

    Again, it still confirms that the employeeList, by definition, cannot be empty.

  17. mvtglobally commented on May 13, 2024

    @mvtglobally

    Issue not reproducible during KI retests. (Second week)

  18. melvin-bot commented on May 13, 2024

    @melvin-bot

    @puneetlath, @hungvu193 Huh... This is 4 days overdue. Who can take care of this?

  19. melvin-bot commented on May 15, 2024

    @melvin-bot

    📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

  20. melvin-bot commented on May 15, 2024

    @melvin-bot

    @puneetlath, @hungvu193 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

  21. puneetlath commented on May 16, 2024

    @puneetlath
    Contributor

    Ok, based on the discussion I agree that we can close this out. Thanks everyone.

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

Metadata

Metadata

Labels

DailyKSv2EngineeringExternalAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributors

Type

No type

Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions