Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HOLD for payment 07-31-2024][$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors #43791

Closed
1 of 6 tasks
m-natarajan opened this issue Jun 14, 2024 · 45 comments
Assignees
Labels
AutoAssignerNewDotQuality Used to assign quality issues to engineers Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review

Comments

@m-natarajan
Copy link

m-natarajan commented Jun 14, 2024

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: v1.4.83-3
Reproducible in staging?: y
Reproducible in production?: y
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
Expensify/Expensify Issue URL:
Issue reported by: @muttmuure
Slack conversation: https://expensify.slack.com/archives/C05LX9D6E07/p1718365848007159

Action Performed:

  1. Go to staging.new.expensify.com
  2. Click on any report in LHN

Expected Result:

Skeleton animation work as expected

Actual Result:

At times the static image of the skeleton shows and the skeleton doesn’t appear at all.

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

Blurred.animations.mov
Recording.220.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~013a31dcebc0c8e5de
  • Upwork Job ID: 1802755576680221726
  • Last Price Increase: 2024-06-17
  • Automatic offers:
    • akinwale | Reviewer | 102780731
    • tsa321 | Contributor | 102780734
Issue OwnerCurrent Issue Owner: @akinwale
@m-natarajan m-natarajan added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. AutoAssignerNewDotQuality Used to assign quality issues to engineers labels Jun 14, 2024
@m-natarajan m-natarajan moved this to CRITICAL in [#whatsnext] #quality Jun 14, 2024
Copy link

melvin-bot bot commented Jun 14, 2024

Triggered auto assignment to @lschurr (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

Copy link

melvin-bot bot commented Jun 14, 2024

Triggered auto assignment to @tgolen (AutoAssignerNewDotQuality)

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Jun 14, 2024
@tsa321
Copy link
Contributor

tsa321 commented Jun 15, 2024

Proposal

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

UX Reliability issue: The loading skeleton exhibits three different behaviors. Sometimes skeleton view shown above one or two report actions, sometimes doesn't show up, sometimes full cover skeleton shown in

What is the root cause of that problem?

When user open app / first OpenApp, back end returns certain reportActions types (IOU report actions, reportpreview aciton, and some others...). There are three different case:

  1. When opening a report the report actions returned by OpenApp will be displayed at bottom and skeleton shown above it. When OpenReport request completed the report actions moved to proper position.

  2. For other case when full skeleton view is displayed it means, there is no cached report actions (there is no report actions type IOU, or other type that returned by OpenApp). So cached report actions is empty.

  3. Case when user open report then App immediately displays the messages, it means there are cached report actions in onyx.

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

When opening a report, OpenReport will return around 100 latest reportActions. We could show full skeleton view when getContinous reportActions :

const reportActions = useMemo(() => {
if (!sortedAllReportActions.length) {
return [];
}
return ReportActionsUtils.getContinuousReportActionChain(sortedAllReportActions, reportActionIDFromRoute);

When the continuous reportActions doesn't reach around 50 / 100 or the oldest reportAction type isn't CREATED type.
We should wait for OpenReport to be completed and show the full skeleton view.

In the end there will be two behavior, If cached report actions exist and fulfill the criteria above we immediately show it. If the above criteria doesn't met we display full skeleton view and wait for OpenReport to be completed.

const shouldShowSkeleton =
!isLinkedMessageAvailable &&
(isLinkingToMessage ||

The shouldShowSkeleton could be:

const isCreatedActionExist = ReportActionsUtils.isCreatedAction(reportActions.at(-1));
const shouldShowSkeleton = 
        (isLinkingToMessage && !isLinkedMessageAvailable) ||
        (reportActions.length < 50 && !isCreatedActionExist && !!reportMetadata?.isLoadingInitialReportActions) ||
        isLoading ||
        (!!reportActionIDFromRoute && reportMetadata?.isLoadingInitialReportActions);

The in here
the condition to show reportActionsView is !shouldShowSkeleton

Result:
web.mp4

@melvin-bot melvin-bot bot added the Overdue label Jun 17, 2024
@tgolen
Copy link
Contributor

tgolen commented Jun 17, 2024

I'm going to discuss this internally first to see what the expected behavior should be.

@melvin-bot melvin-bot bot removed the Overdue label Jun 17, 2024
@muttmuure muttmuure changed the title UX Reliability issue: The loading skeleton exhibits three different behaviors CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors Jun 17, 2024
@tgolen tgolen added the External Added to denote the issue can be worked on by a contributor label Jun 17, 2024
@melvin-bot melvin-bot bot changed the title CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors [$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors Jun 17, 2024
Copy link

melvin-bot bot commented Jun 17, 2024

Job added to Upwork: https://www.upwork.com/jobs/~013a31dcebc0c8e5de

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Jun 17, 2024
Copy link

melvin-bot bot commented Jun 17, 2024

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

@tgolen
Copy link
Contributor

tgolen commented Jun 17, 2024

OK, it sounds like the solution from @tsa321 is inline with our expectations. I'm going to label this as external and then the C+ can give the proposal a look.

@muttmuure
Copy link
Contributor

@abdulrahuman5196 is ooo, let's reapply the label

@muttmuure muttmuure added External Added to denote the issue can be worked on by a contributor and removed External Added to denote the issue can be worked on by a contributor labels Jun 17, 2024
Copy link

melvin-bot bot commented Jun 17, 2024

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

@akinwale
Copy link
Contributor

@tsa321's proposal makes sense here.

🎀👀🎀 C+ reviewed.

@tsa321
Copy link
Contributor

tsa321 commented Jul 10, 2024

@akinwale PR is ready

@lschurr
Copy link
Contributor

lschurr commented Jul 10, 2024

Just clarifying - What are we waiting on here @akinwale @tsa321? Is this bug now fixed?

@akinwale
Copy link
Contributor

@lschurr There was a regression, so I'll need to review the PR.

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Jul 10, 2024
@lschurr lschurr changed the title [HOLD for payment 2024-07-10] [HOLD on #44625][$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors [HOLD on #44625][$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors Jul 10, 2024
@lschurr lschurr removed the Awaiting Payment Auto-added when associated PR is deployed to production label Jul 10, 2024
@lschurr
Copy link
Contributor

lschurr commented Jul 16, 2024

Any update here @akinwale? Have you had a chance to review the PR?

@akinwale
Copy link
Contributor

Any update here @akinwale? Have you had a chance to review the PR?

Not yet. I will wrap this up tonight. Thanks for the reminder.

Copy link

melvin-bot bot commented Jul 22, 2024

⚠️ Looks like this issue was linked to a Deploy Blocker here

If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

If a regression has occurred and you are the assigned CM follow the instructions here.

If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

Copy link

melvin-bot bot commented Jul 23, 2024

@tgolen, @akinwale, @lschurr, @tsa321 Whoops! This issue is 2 days overdue. Let's get this updated quick!

Copy link

melvin-bot bot commented Jul 25, 2024

@tgolen, @akinwale, @lschurr, @tsa321 Eep! 4 days overdue now. Issues have feelings too...

@tsa321
Copy link
Contributor

tsa321 commented Jul 25, 2024

Update: The PR was deployed to production 3 days ago.

Copy link

melvin-bot bot commented Jul 29, 2024

@tgolen, @akinwale, @lschurr, @tsa321 Now this issue is 8 days overdue. Are you sure this should be a Daily? Feel free to change it!

@akinwale
Copy link
Contributor

@lschurr It looks like this is ready for payment as the follow-up PR has been in production for over a week now. Thanks.

@lschurr
Copy link
Contributor

lschurr commented Jul 30, 2024

Thanks @akinwale - And just to clarify, the original bug here is now fixed, but the first PR caused a regression, correct? #44488 fixed that, right?

@lschurr lschurr changed the title [HOLD on #44625][$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors [HOLD for payment 07-31-2024][$250] CRITICAL [UX Reliability] The loading skeleton exhibits three different behaviors Jul 30, 2024
@akinwale
Copy link
Contributor

Thanks @akinwale - And just to clarify, the original bug here is now fixed, but the first PR caused a regression, correct? #44488 fixed that, right?

Yes, this is correct.

@lschurr
Copy link
Contributor

lschurr commented Jul 31, 2024

Payment summary (50% due to regression):

  • Contributor: $125 @tsa321 (paid in Upwork)
  • Reviewer: $125 @akinwale (paid in Upwork)

@lschurr
Copy link
Contributor

lschurr commented Jul 31, 2024

Payments are complete.

@lschurr lschurr closed this as completed Jul 31, 2024
@github-project-automation github-project-automation bot moved this from CRITICAL to Done in [#whatsnext] #quality Jul 31, 2024
@muttmuure
Copy link
Contributor

I think we needed a regression test for this one

@muttmuure
Copy link
Contributor

Do you think we can create a regression test here? @akinwale?

@akinwale
Copy link
Contributor

  • [@akinwale] The PR that introduced the bug has been identified. Link to the PR:
  • [@akinwale] 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:
  • [@akinwale] 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:

Not a regression.

  • [@akinwale] Determine if we should create a regression test for this bug.
  • [@akinwale] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.

Regression Test Steps

  1. Launch Expensify
  2. If already logged in, sign out and then log in again
  3. Open an IOU request report.
  4. Verify that the The IOU preview is not displayed, but the full loading skeleton is displayed until data is received from the server.
  5. Open another report and then reopen the initial IOU report.
  6. Verify that the initial IOU report opens instantly.
  7. Repeat steps 3 through 6 for other kinds of reports.
  8. Click the IOU report preview.
  9. Verify that the transaction report is opened.
  10. Navigate back using the header link from the transaction report using the header link.
  11. Verify that navigation occurs correctly back to the report preview.

Do we agree 👍 or 👎?

@akinwale
Copy link
Contributor

@muttmuure Done.

@lschurr
Copy link
Contributor

lschurr commented Sep 12, 2024

@lschurr lschurr closed this as completed Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AutoAssignerNewDotQuality Used to assign quality issues to engineers Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review
Projects
Development

No branches or pull requests

7 participants