App icon indicating copy to clipboard operation
App copied to clipboard

[$250] Room - In room created with dependent tags enabled workspace, state tags shown in expense preview

Open vincdargento opened this issue 1 year ago β€’ 8 comments

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 9.0.70-0 Reproducible in staging?: Yes Reproducible in production?: Yes If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Yes If this was caught during regression testing, add the test name, ID and link from TestRail: N/A Email or phone of affected tester (no customers): N/A Issue reported by: Applause Internal Team

Action Performed:

  1. Launch app
  2. Go to workspace settings ( a workspace with dependent tags added in old dot)
  3. Tap tags and note dependent tags
  4. Navigate to LHN and create a room with above workspace
  5. Invite a member via mention
  6. Create a split expense
  7. Note expense preview displays state tag
  8. Go to workspace settings and enable tag feature
  9. Add a tag
  10. Navigate to LHN and create a room with above workspace
  11. Invite a member via mention
  12. Create a split expense
  13. Note expense preview doesn't displays tag

Expected Result:

In confirmation page, no tag option and so after creating expense, in preview

Actual Result:

In room created with dependent tags enabled workspace, state tags shown in expense preview. But tag not shown in preview for room created with ordinary tags enabled.

Workaround:

Unknown

Platforms:

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

  • [x] Android: Standalone
  • [x] Android: HybridApp
  • [x] Android: mWeb Chrome
  • [ ] iOS: Standalone
  • [ ] iOS: HybridApp
  • [ ] iOS: mWeb Safari
  • [x] MacOS: Chrome / Safari
  • [ ] MacOS: Desktop

Screenshots/Videos

https://github.com/user-attachments/assets/559d225f-24e3-48ac-bdaf-d2c9399041bb

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021865094255127866607
  • Upwork Job ID: 1865094255127866607
  • Last Price Increase: 2024-12-06
  • Automatic offers:
    • abzokhattab | Contributor | 105256689
Issue OwnerCurrent Issue Owner: @jayeshmangwani

vincdargento avatar Dec 03 '24 13:12 vincdargento

Triggered auto assignment to @CortneyOfstad (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.

melvin-bot[bot] avatar Dec 03 '24 13:12 melvin-bot[bot]

Proposal

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

Inconsistency in the tag field between the split report preview and the split confirm and details

What is the root cause of that problem?

this inconsistency occurs because in the split confirm page we dont show the tag if the split is not an expense report chat however we dont check that in the split preview:

https://github.com/Expensify/App/blob/d5e8710e2fa3125e1fb273ce63493caeca15e263/src/components/MoneyRequestConfirmationListFooter.tsx#L228

https://github.com/Expensify/App/blob/d9e53c7b8ff8fe17d3536508c83824a246f218b1/src/components/ReportActionItem/MoneyRequestPreview/MoneyRequestPreviewContent.tsx#L150

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

we should add a check to validate that the current report is isPolicyExpenseChatso we should change this to

    const shouldShowTag = !!tag && isPolicyExpenseChat;
    const shouldShowCategoryOrTag = shouldShowTag || !!category;

and here we should use shouldShowTag instead of the tag

What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

N/A

What alternative solutions did you explore? (Optional)

another solution is to prevent setting the tag in request transaction if the chat is not a isPolicyExpenseChat https://github.com/Expensify/App/blob/30483a8f1d95f01f080978025694a3c2e5a6d9c6/src/components/MoneyRequestConfirmationList.tsx#L695-L697

        if (updatedTagsString !== TransactionUtils.getTag(transaction) && updatedTagsString && isPolicyExpenseChat) {
            IOU.setMoneyRequestTag(transactionID, updatedTagsString);
        }

abzokhattab avatar Dec 03 '24 13:12 abzokhattab

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

melvin-bot[bot] avatar Dec 06 '24 18:12 melvin-bot[bot]

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

melvin-bot[bot] avatar Dec 06 '24 18:12 melvin-bot[bot]

I was not able to reproduce this β€” going to have this retested!

CortneyOfstad avatar Dec 06 '24 18:12 CortneyOfstad

@abzokhattab 's Proposal looks good to me. We can add the isPolicyExpenseChat check for showing the tag on MoneyRequestPreviewContent. We're doing the same on the Split Details page, so it seems fine here too.

πŸŽ€ πŸ‘€ πŸŽ€ C+ reviewed

jayeshmangwani avatar Dec 09 '24 09:12 jayeshmangwani

Triggered auto assignment to @cristipaval, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

melvin-bot[bot] avatar Dec 09 '24 09:12 melvin-bot[bot]

πŸ“£ @abzokhattab πŸŽ‰ An offer has been automatically sent to your Upwork account for the Contributor role πŸŽ‰ Thanks for contributing to the Expensify app!

Offer link Upwork job Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review πŸ§‘β€πŸ’» Keep in mind: Code of Conduct | Contributing πŸ“–

melvin-bot[bot] avatar Dec 09 '24 12:12 melvin-bot[bot]

@abzokhattab What's the ETA for the PR?

jayeshmangwani avatar Dec 11 '24 06:12 jayeshmangwani

the pr is ready here https://github.com/Expensify/App/pull/53973

abzokhattab avatar Dec 11 '24 23:12 abzokhattab

Hey @jayeshmangwani and @abzokhattab β€” just a heads up that I will be OOO starting this afternoon (December 20th) and will be returning January 6th. A handful of folks on the BZ team will be online for a few days in between the 25th and the 1st, but we'll be operating with a skeleton crew. If there is any action needed from a BZ perspective, feel free to please post this issue in #expensify-open-source and someone on the team will jump in. Otherwise, I'll review when I'm back in office.

Thank you and Happy Holidays!

CortneyOfstad avatar Dec 20 '24 20:12 CortneyOfstad

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

melvin-bot[bot] avatar Dec 23 '24 21:12 melvin-bot[bot]

The solution for this issue has been :rocket: deployed to production :rocket: in version 9.0.77-6 and is now subject to a 7-day regression period :calendar:. Here is the list of pull requests that resolve this issue:

  • https://github.com/Expensify/App/pull/53973

If no regressions arise, payment will be issued on 2024-12-30. :confetti_ball:

For reference, here are some details about the assignees on this issue:

  • @jayeshmangwani requires payment through NewDot Manual Requests
  • @abzokhattab requires payment automatic offer (Contributor)

melvin-bot[bot] avatar Dec 23 '24 21:12 melvin-bot[bot]

@jayeshmangwani @CortneyOfstad @jayeshmangwani The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

melvin-bot[bot] avatar Dec 23 '24 21:12 melvin-bot[bot]

BugZero Checklist:

  • [x] [Contributor] Classify the bug:
Bug classification

Source of bug:

  • [x] 1a. Result of the original design (eg. a case wasn't considered)
  • [ ] 1b. Mistake during implementation
  • [ ] 1c. Backend bug
  • [ ] 1z. Other:

Where bug was reported:

  • [x] 2a. Reported on production (eg. bug slipped through the normal regression and PR testing process on staging)
  • [ ] 2b. Reported on staging (eg. found during regression or PR testing)
  • [ ] 2d. Reported on a PR
  • [ ] 2z. Other:

Who reported the bug:

  • [ ] 3a. Expensify user
  • [ ] 3b. Expensify employee
  • [ ] 3c. Contributor
  • [x] 3d. QA
  • [ ] 3z. Other:
  • [x] [Contributor] 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: https://github.com/Expensify/App/pull/52758/files#r1900565905

  • [x] [Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source 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: N/A

  • [x] [Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.

Regression Test Proposal

Prerequisites:

  • A workspace is created with dependent tags added in the OldDot.
  1. Go to workspace settings ( a workspace with dependent tags added in old dot)
  2. Tap Tags and note the dependent tags.
  3. Navigate to the LHN and create a room using the above workspace.
  4. Invite a member via mention.
  5. Create a split expense.
  6. Verify that the expense preview does not display the tag in the preview.

Do we agree πŸ‘ or πŸ‘Ž

jayeshmangwani avatar Jan 02 '25 06:01 jayeshmangwani

@CortneyOfstad, @cristipaval, @jayeshmangwani, @abzokhattab Whoops! This issue is 2 days overdue. Let's get this updated quick!

melvin-bot[bot] avatar Jan 02 '25 09:01 melvin-bot[bot]

Not Overdue; payment is due here, but @CortneyOfstad is OOO until January 6th, so we can wait until then.

jayeshmangwani avatar Jan 02 '25 22:01 jayeshmangwani

@CortneyOfstad, @cristipaval, @jayeshmangwani, @abzokhattab 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

melvin-bot[bot] avatar Jan 06 '25 09:01 melvin-bot[bot]

@CortneyOfstad Whenever you can, please add the payment summary here for this issue and close it too.

jayeshmangwani avatar Jan 07 '25 11:01 jayeshmangwani

@jayeshmangwani β€” I sent you an offer in Upwork for the payment here β€” https://www.upwork.com/nx/wm/offer/105597059. Let me know once you accept and I'll get that paid ASAP. Thank you!

CortneyOfstad avatar Jan 07 '25 16:01 CortneyOfstad

@CortneyOfstad I paid via ND and @abzokhattab paid via Upwork

jayeshmangwani avatar Jan 07 '25 16:01 jayeshmangwani

Sorry about that @jayeshmangwani β€” I don't see you on the list, so I will get that updated now internally, and I will cancel the offer and get the payment summary out ASAP.

CortneyOfstad avatar Jan 07 '25 17:01 CortneyOfstad

Payment Summary

@jayeshmangwani β€” to be paid $250 via NewDot @abzokhattab β€” to be paid $250 via NewDot

Regression Test

https://github.com/Expensify/Expensify/issues/458072

CortneyOfstad avatar Jan 07 '25 17:01 CortneyOfstad

$250 approved for @jayeshmangwani

garrettmknight avatar Jan 21 '25 11:01 garrettmknight