You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[HOLD for payment 2024-01-31] [$500] Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section #33768
Version Number: v1.4.19-1 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: Applause - Internal Team Slack conversation:
Action Performed:
Precondition:
User is an employee of a Collect workspace.
The workspace has categories and tags.
Go to workspace chat > + > Split bill > Scan.
Create a split scan request with a category.
Click on the split scan preview.
Manually enter amount and merchant (this step is not necessary).
Click + > Request money > Manual.
Enter amount > Next > Show more.
Click Category.
Expected Result:
The category previously selected for split scan request is present in Recent section.
Actual Result:
The category previously selected for split scan request is not present in Recent section.
The same issue happens with Tag in split scan request as well.
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
changed the title [-]Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section[/-][+][$500] Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section[/+]on Dec 29, 2023
Please re-state the problem that we are trying to solve in this issue.
Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section
What is the root cause of that problem?
If we create a split bill request with receipt we use IOU.startSplitBill but we have not implemented the code that saves recentlyUsedTags and recentlyUsedCategories in onyx in IOU.startSplitBill as we did in IOU.splitBill here
Please re-state the problem that we are trying to solve in this issue.
The category previously selected for split scan request is not present in Recent section.
The same issue happens with Tag in split scan request as well.
What is the root cause of that problem?
In Split Scan Request, we are using startSplitBill function but in this function we don't have any logic to update optimisticPolicyRecentlyUsedCategories and optimisticPolicyRecentlyUsedTags
What changes do you think we should make in order to solve the problem?
Note that: we only need to update optimisticPolicyRecentlyUsedCategories and optimisticPolicyRecentlyUsedTags if we split bill (scan request) in a workspace chat (isPolicyExpenseChat === true)
So that we should add condition to check if the participant is policy expense chat and category/tag is not empty we will update recently used category/tags
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.30-1 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
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:
[@parasharrajat] The PR that introduced the bug has been identified. Link to the PR:
[@parasharrajat] 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:
[@parasharrajat] 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:
[@parasharrajat] Determine if we should create a regression test for this bug.
[@parasharrajat] 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.
[@JmillsExpensify] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
Contributor has been paid out, and C+ is paid via Expensify, so closing out this issue and we can handle the checklist/regression decisions ahead of that step.
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:
[@parasharrajat] The PR that introduced the bug has been identified. Link to the PR: No PR is responsible for the issue. We never implemented the required changes on the startSplitBill flow while adding it to only splitbill. I consider the presence of two functions to be the cause of this issue as it is easy to miss one flow while updating one. We should have only one abstract function which might switch flow as per need.
[@parasharrajat] 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: NA
[@parasharrajat] 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: NA
[@parasharrajat] Determine if we should create a regression test for this bug. Yes
[@parasharrajat] 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
Note:
1. User is an employee of a Collect workspace.
2. The workspace has categories and tags 8+ each.
Go to workspace chat > + > Split bill > Scan.
Create a split scan request with a category and tag.
Click on the split scan preview.
Manually enter the amount and merchant (this step is not necessary).
Click + > Request money > Manual.
Enter amount > Next > Show more.
Click Category and verify that the category you selected in (2) is listed under recent categories
Click Tag and verify that the tag you selected in (2) is listed under recent tags.
Activity
melvin-bot commentedon Dec 29, 2023
Job added to Upwork: https://www.upwork.com/jobs/~010b2b5eecc8b4c1e2
[-]Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section[/-][+][$500] Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section[/+]melvin-bot commentedon Dec 29, 2023
Triggered auto assignment to @JmillsExpensify (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.melvin-bot commentedon Dec 29, 2023
Bug0 Triage Checklist (Main S/O)
Platformsin OP are ✅)melvin-bot commentedon Dec 29, 2023
Triggered auto assignment to Contributor-plus team member for initial proposal review - @parasharrajat (
External)FitseTLT commentedon Dec 29, 2023
Proposal
Please re-state the problem that we are trying to solve in this issue.
Category & Tag - Category/Tag used in Split Scan request does not appear in the Recent section
What is the root cause of that problem?
If we create a split bill request with receipt we use
IOU.startSplitBillbut we have not implemented the code that savesrecentlyUsedTagsandrecentlyUsedCategoriesin onyx inIOU.startSplitBillas we did inIOU.splitBillhereApp/src/libs/actions/IOU.js
Lines 1410 to 1415 in 7d1b0f8
What changes do you think we should make in order to solve the problem?
We should implement the logic that saves the
recentlyUsedTagsandrecentlyUsedCategoriesinIOU.startSplitBillas we did inIOU.splitBillhere
App/src/libs/actions/IOU.js
Lines 1623 to 1624 in 7d1b0f8
What alternative solutions did you explore? (Optional)
DylanDylann commentedon Dec 30, 2023
Proposal
Please re-state the problem that we are trying to solve in this issue.
The category previously selected for split scan request is not present in Recent section.
The same issue happens with Tag in split scan request as well.
What is the root cause of that problem?
In Split Scan Request, we are using
startSplitBillfunction but in this function we don't have any logic to updateoptimisticPolicyRecentlyUsedCategoriesandoptimisticPolicyRecentlyUsedTagsWhat changes do you think we should make in order to solve the problem?
Note that: we only need to update
optimisticPolicyRecentlyUsedCategoriesandoptimisticPolicyRecentlyUsedTagsif we split bill (scan request) in a workspace chat (isPolicyExpenseChat === true)So that we should add condition to check if the participant is policy expense chat and category/tag is not empty we will update recently used category/tags
In here
App/src/libs/actions/IOU.js
Lines 1645 to 1647 in 8cb48e4
We should add
One more thing, we are using the same logic to update recently used category/tags in many places. So we should create new utils function to dry code
What alternative solutions did you explore? (Optional)
NA
melvin-bot commentedon Jan 1, 2024
@JmillsExpensify, @parasharrajat Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
23 remaining items
melvin-bot commentedon Jan 24, 2024
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Jan 24, 2024
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.30-1 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-01-31. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Jan 24, 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:
JmillsExpensify commentedon Jan 31, 2024
@parasharrajat Do you mind helping with the BZ checklist?
JmillsExpensify commentedon Jan 31, 2024
In the meantime, payment summary as follows:
JmillsExpensify commentedon Jan 31, 2024
Contributor has been paid out, and C+ is paid via Expensify, so closing out this issue and we can handle the checklist/regression decisions ahead of that step.
parasharrajat commentedon Feb 5, 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:
Regression Test Steps
Note:
1. User is an employee of a Collect workspace.
2. The workspace has categories and tags 8+ each.
Do you agree 👍 or 👎 ?
JmillsExpensify commentedon Feb 10, 2024
That sounds good to me. I created a regression test, so at this point I'm waiting on the money request in Expensify and I'll come back to approve.
parasharrajat commentedon May 13, 2024
Payment requested as per #33768 (comment)
JmillsExpensify commentedon May 19, 2024
Need someone else on the BZ team to confirm that this payment summary is right before I can approve payment.
mallenexpensify commentedon May 20, 2024
Contributor: @FitseTLT paid $500 via Upwork
Contributor+: @parasharrajat owed $500 via NewDot
JmillsExpensify commentedon May 31, 2024
$500 approved for @parasharrajat