Skip to content

[HOLD for payment 2024-04-15] IOU - Skeleton IOU preview appears in IOU details page when there is one request #39403

Description

@kbecciv

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.59-0
Reproducible in staging?: y
Reproducible in production?: n
Issue reported by: Applause - Internal Team

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to FAB > Request money.
  3. Create a manual request from any user.
  4. In 1:1 DM, click on the IOU preview.

Expected Result:

There will no be preview in transaction thread.

Actual Result:

A skeleton preview is shown in transaction thread.

Workaround:

n/a

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

Bug6435479_1712058056237.IOU.mp4

View all open jobs on GitHub

Activity

  1. melvin-bot commented on Apr 2, 2024

    @melvin-bot

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

  2. kbecciv commented on Apr 2, 2024

    @kbecciv
    Author

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

  3. github-actions commented on Apr 2, 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.
  4. paultsimura commented on Apr 2, 2024

    @paultsimura
    Contributor

    Proposal

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

    The empty skeleton report action is added for a one-transaction IOU Report view.

    What is the root cause of that problem?

    This was caused by #36934 which introduced the one-transaction view.
    The reason is that we filter out the IOU Report Action from the list if it's a single-transaction report.

    But later here, we build an optimistic report preview action (the skeleton one) if the amount of filtered transactions is less than reportPreviewAction?.childMoneyRequestCount:

    if (report.total && moneyRequestActions.length < (reportPreviewAction?.childMoneyRequestCount ?? 0)) {
    const optimisticIOUAction = ReportUtils.buildOptimisticIOUReportAction(
    CONST.IOU.REPORT_ACTION_TYPE.CREATE,
    0,
    CONST.CURRENCY.USD,
    '',
    [],
    NumberUtils.rand64(),
    undefined,
    report.reportID,
    false,
    false,
    {},
    false,
    DateUtils.subtractMillisecondsFromDateTime(actions[actions.length - 1].created, 1),
    ) as OnyxTypes.ReportAction;
    moneyRequestActions.push(optimisticIOUAction);
    actions.splice(actions.length - 1, 0, optimisticIOUAction);
    }

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

    We need to count for the special one-transaction case now, and change the condition to:

    if (report.total && !isOneTransactionView && moneyRequestActions.length < (reportPreviewAction?.childMoneyRequestCount ?? 0)) {
    ...

    Where the isOneTransactionView might be reportPreviewAction?.childMoneyRequestCount === 1 (need to verify this deeper into the original PR).

    What alternative solutions did you explore? (Optional)

  5. NikkiWines commented on Apr 2, 2024

    @NikkiWines
    Contributor

    Oh, yep - definitely introduced by #36934. We should be using combinedReportActions there and also if we've passed a transactionThreadReport we know that the report is a one-transaction report and should skip the optimistic preview.

  6. NikkiWines commented on Apr 2, 2024

    @NikkiWines
    Contributor

    @puneetlath I'll spin up a PR to handle the couple blockers that #36934 introduced, so i can take this over if you'd like

  7. melvin-bot commented on Apr 2, 2024

    @melvin-bot

    ⚠️ 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.

  8. self-assigned this
    on Apr 2, 2024
  9. melvin-bot commented on Apr 2, 2024

    @melvin-bot

    ⚠️ 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.

  10. NikkiWines commented on Apr 2, 2024

    @NikkiWines
    Contributor

    No skeleton on staging 🎊

    Screen.Recording.2024-04-02.at.15.13.01.mov
  11. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Apr 8, 2024
  12. changed the title [-]IOU - Skeleton IOU preview appears in IOU details page when there is one request[/-] [+][HOLD for payment 2024-04-15] IOU - Skeleton IOU preview appears in IOU details page when there is one request[/+] on Apr 8, 2024
  13. melvin-bot commented on Apr 8, 2024

    @melvin-bot

    Reviewing label has been removed, please complete the "BugZero Checklist".

  14. melvin-bot commented on Apr 8, 2024

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.60-13 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 2024-04-15. 🎊

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

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions