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 2024-02-19] [$500] [LOW] Selecting tag on Split bill does not work #35836

Closed
1 of 6 tasks
mountiny opened this issue Feb 5, 2024 · 19 comments
Closed
1 of 6 tasks
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor

Comments

@mountiny
Copy link
Contributor

mountiny commented Feb 5, 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: 1.4.37.0
Reproducible in staging?: main
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
Expensify/Expensify Issue URL:
Issue reported by: @rezkiy37
Slack conversation:

Action Performed:

Break down in numbered steps

  1. Be a member of a workspace with tags.
  2. Open own policy expense chat.
  3. Click on the “+” (actions).
  4. Click on “Split bill”.
  5. Select “Manual”.
  6. Enter any amount.
  7. Click on “Next”.
  8. Click on “Show more”.
  9. Click on a tag row.
  10. Select any tag.

Expected Result:

Describe what you think should've happened

The tag row should contain a previously selected tag.

Actual Result:

Describe what actually happened

The previously selected tag has not been applied for a split bill.

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: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

#34983 (comment)

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0105b7db6cc3d465b3
  • Upwork Job ID: 1754544056596803584
  • Last Price Increase: 2024-02-05
  • Automatic offers:
    • jjcoffee | Reviewer | 28145956
    • paultsimura | Contributor | 28145958
@mountiny mountiny added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor labels Feb 5, 2024
@melvin-bot melvin-bot bot changed the title Selecting tag on Split bill does not work [$500] Selecting tag on Split bill does not work Feb 5, 2024
Copy link

melvin-bot bot commented Feb 5, 2024

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

Copy link

melvin-bot bot commented Feb 5, 2024

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

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

melvin-bot bot commented Feb 5, 2024

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

@paultsimura
Copy link
Contributor

paultsimura commented Feb 5, 2024

Proposal

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

While creating a Split request, setting a tag doesn't work.

What is the root cause of that problem?

The issue lies here:

if (isSplitBill) {
IOU.setDraftSplitTransaction(transactionID, {tag: selectedTag.searchText});
navigateBack();
return;
}

This was supposed to handle the Split Bill modifications, which use the SPLIT_TRANSACTION_DRAFT Onyx key. However, when creating a request, we use the TRANSACTION_DRAFT. Therefore, this operation updates the wrong Onyx key.

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

We should move this split-check inside the isEditing check:

        if (isEditing) {
            if (isSplitBill) {
                IOU.setDraftSplitTransaction(transactionID, {tag: selectedTag.searchText});
                navigateBack();
                return;
            }
            IOU.updateMoneyRequestTag(transactionID, report.reportID, updatedTag);
            Navigation.dismissModal();
            return;
        }

Or simply add the && isEditing check to it:

        if (isSplitBill && isEditing) {
            IOU.setDraftSplitTransaction(transactionID, {tag: selectedTag.searchText});
            navigateBack();
            return;
        }
        if (isEditing) {
            IOU.updateMoneyRequestTag(transactionID, report.reportID, updatedTag);
            Navigation.dismissModal();
            return;
        }

if (isEditing) {
IOU.updateMoneyRequestTag(transactionID, report.reportID, updatedTag);
Navigation.dismissModal();
return;
}

What alternative solutions did you explore? (Optional)

@mountiny
Copy link
Contributor Author

mountiny commented Feb 5, 2024

@jjcoffee can you please review?

@jjcoffee
Copy link
Contributor

jjcoffee commented Feb 6, 2024

@paultsimura's proposal LGTM! This looks like a regression from #35136.

🎀👀🎀 C+ reviewed

Copy link

melvin-bot bot commented Feb 6, 2024

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

@pecanoro
Copy link
Contributor

pecanoro commented Feb 6, 2024

Sounds good! Assigning @paultsimura

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Feb 6, 2024
Copy link

melvin-bot bot commented Feb 6, 2024

📣 @jjcoffee 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job

Copy link

melvin-bot bot commented Feb 6, 2024

📣 @paultsimura 🎉 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 melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Feb 6, 2024
@paultsimura
Copy link
Contributor

Thanks. The PR is ready for review: #35913

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Feb 12, 2024
@melvin-bot melvin-bot bot changed the title [$500] Selecting tag on Split bill does not work [HOLD for payment 2024-02-19] [$500] Selecting tag on Split bill does not work Feb 12, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Feb 12, 2024
Copy link

melvin-bot bot commented Feb 12, 2024

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

Copy link

melvin-bot bot commented Feb 12, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.39-8 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-02-19. 🎊

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

Copy link

melvin-bot bot commented Feb 12, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@jjcoffee] The PR that introduced the bug has been identified. Link to the PR:
  • [@jjcoffee] 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:
  • [@jjcoffee] 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:
  • [@jjcoffee] Determine if we should create a regression test for this bug.
  • [@jjcoffee] 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.
  • [@Christinadobrzyn] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@jjcoffee
Copy link
Contributor

  • The PR that introduced the bug has been identified. Link to the PR: remove MoneyRequestTagPage #35136
  • 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/35136/files#r1492660108
  • 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: N/A - simple mistake
  • Determine if we should create a regression test for this bug. Yes - though one probably already exists!
  • 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 Proposal

  1. Open a policy expense chat on a workspace with tags
  2. Click “+” -> “Split bill” -> “Manual”
  3. Enter any amount and click “Next”
  4. Click “Show more” -> Tag row
  5. Select any tag and verify that it displays in the tag row
  6. Proceed to create the Split request
  7. Open the Split preview and verify the selected tag persisted successfully.

Do we agree 👍 or 👎

@Christinadobrzyn Christinadobrzyn added Daily KSv2 and removed Weekly KSv2 labels Feb 16, 2024
@melvin-bot melvin-bot bot added Daily KSv2 and removed Daily KSv2 labels Feb 18, 2024
@greg-schroeder greg-schroeder changed the title [HOLD for payment 2024-02-19] [$500] Selecting tag on Split bill does not work [HOLD for payment 2024-02-19] [$500] [LOW] Selecting tag on Split bill does not work Feb 20, 2024
@Christinadobrzyn
Copy link
Contributor

hi! Sorry I'm ooo sick today - I'll pay this out tomorrow

@Christinadobrzyn
Copy link
Contributor

Christinadobrzyn commented Feb 21, 2024

Sorry for the delay here - just checking @jjcoffee, are we ready to pay this out - I saw some additional communication in the PR after the production notification.

Payouts due:

Contributor: $500 @paultsimura (paid in Upwork)
Contributor+: $500 @jjcoffee (paid in Upwork)

Eligible for 50% #urgency bonus? NA

Upwork job is here.
Regression test _ https://github.com/Expensify/Expensify/issues/371555

@jjcoffee
Copy link
Contributor

@Christinadobrzyn No worries, hope you're feeling better! This is ready for payout - the PR you've linked is the one that introduced the bug (this is the correct one).

@Christinadobrzyn
Copy link
Contributor

Awesome! thanks @jjcoffee! Paid out based on this payment summary - #35836 (comment)

Feel free to reach out with any questions!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor
Projects
No open projects
Development

No branches or pull requests

5 participants