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-07-10] [Search v1] - Scanning expense displays 0.00 in Total column and the Merchant column is blank #43474

Closed
6 tasks done
m-natarajan opened this issue Jun 11, 2024 · 50 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Internal Requires API changes or must be handled by Expensify staff Weekly KSv2

Comments

@m-natarajan
Copy link

m-natarajan commented Jun 11, 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.81-8
Reproducible in staging?: y
Reproducible in production?: new feature
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:

  1. Go to staging.new.expensify.com
  2. Go to workspace chat.
  3. Submit a scan expense.
  4. While the receipt is scanning, go to Search.

Expected Result:

The scanning expense will display "Scanning" in Merchant and Total column, similar to transaction thread.

Actual Result:

The scanning expense displays 0.00 in Total column, and the Merchant column is blank.

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

Bug6509220_1718101572011.20240611_182221.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @garrettmknight
@m-natarajan m-natarajan added DeployBlockerCash This issue or pull request should block deployment Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. DeployBlocker Indicates it should block deploying the API labels Jun 11, 2024
Copy link

melvin-bot bot commented Jun 11, 2024

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

Copy link

melvin-bot bot commented Jun 11, 2024

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

@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Jun 11, 2024
Copy link
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.

@m-natarajan
Copy link
Author

@garrettmknight FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

@m-natarajan
Copy link
Author

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

@etCoderDysto
Copy link
Contributor

etCoderDysto commented Jun 11, 2024

Proposal

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

Scanning expenses display 0.00 in the Total column, and the Merchant column is blank.

What is the root cause of that problem?

transactionItem.formattedMerchantand transactionItem.formattedMerchant are displayed without checking if a scan request state is "SCANNING". There is no state property on transactionItem.receipt for TotalCell and MerchantCell. Therefore we can't determine if the scan transaction state is "SCANNING" following the same pattern used on MoneyRequestView. This is because BE doesn't return transaction.receipt.state value on a transaction object for Search query, but it does for RequestMoney query.

Search query BE response
Screenshot 2024-06-12 at 5 21 29 in the afternoon

RequestMoney query BE response
Screenshot 2024-06-12 at 5 22 16 in the afternoon

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

  • Update the BE to return a transaction object that has transactionItem.receipt.state value for Search query
  • Then check a scan transaction state following the same pattern as MoneyRequestView
    if (TransactionUtils.hasReceipt(transaction) && TransactionUtils.isReceiptBeingScanned(transaction)) {
    merchantTitle = translate('iou.receiptStatusTitle');
    amountTitle = translate('iou.receiptStatusTitle');
  • Display transactionItem.formattedTotal and transactionItem.formattedMerchant, if scan transaction stat is 'SACNNING' or display 'Scanning...' if the sate is not 'SCANNING'

What alternative solutions did you explore? (Optional)

N/A

@carlosmiceli
Copy link
Contributor

Looking at the checklist, I don't think this is a deploy blocker, but it does look like a bug that could be External.

@carlosmiceli carlosmiceli added External Added to denote the issue can be worked on by a contributor and removed DeployBlockerCash This issue or pull request should block deployment DeployBlocker Indicates it should block deploying the API labels Jun 11, 2024
Copy link

melvin-bot bot commented Jun 11, 2024

Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.

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

melvin-bot bot commented Jun 11, 2024

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

@mollfpr
Copy link
Contributor

mollfpr commented Jun 11, 2024

Checking 👀

@carlosmiceli
Copy link
Contributor

@garrettmknight question, why does it say "Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue." when adding the External label?

@carlosmiceli carlosmiceli added Daily KSv2 and removed Hourly KSv2 labels Jun 11, 2024
@luacmartins
Copy link
Contributor

@JmillsExpensify @trjExpensify what's the expected behavior here?

@luacmartins luacmartins changed the title Search - Scanning expense displays 0.00 in Total column and the Merchant column is blank [Search v1] - Scanning expense displays 0.00 in Total column and the Merchant column is blank Jun 11, 2024
@luacmartins
Copy link
Contributor

Approved & merged

@etCoderDysto
Copy link
Contributor

@mollfpr PR is ready for review.

Copy link

melvin-bot bot commented Jun 28, 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.

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Jun 28, 2024
@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Jul 3, 2024
@melvin-bot melvin-bot bot changed the title [Search v1] - Scanning expense displays 0.00 in Total column and the Merchant column is blank [HOLD for payment 2024-07-10] [Search v1] - Scanning expense displays 0.00 in Total column and the Merchant column is blank Jul 3, 2024
Copy link

melvin-bot bot commented Jul 3, 2024

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

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Jul 3, 2024
Copy link

melvin-bot bot commented Jul 3, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.3-7 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-07-10. 🎊

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

  • @mollfpr requires payment through NewDot Manual Requests
  • @etCoderDysto requires payment (Needs manual offer from BZ)

Copy link

melvin-bot bot commented Jul 3, 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:

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

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Jul 10, 2024
Copy link

melvin-bot bot commented Jul 10, 2024

Payment Summary

Upwork Job

BugZero Checklist (@garrettmknight)

  • I have verified the correct assignees and roles are listed above and updated the neccesary manual offers
  • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants//hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@garrettmknight
Copy link
Contributor

garrettmknight commented Jul 10, 2024

Payment Summary:

@etCoderDysto offer out to you in Upwork

@etCoderDysto
Copy link
Contributor

I have accepted the offer. Thank you!

@garrettmknight garrettmknight added Weekly KSv2 and removed Daily KSv2 labels Jul 11, 2024
@garrettmknight
Copy link
Contributor

Contributor paid, dropping to weekly for reveiwer to request.

@mollfpr
Copy link
Contributor

mollfpr commented Jul 11, 2024

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

No offending PR was found.

[@mollfpr] 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:

The regression step should be enough.

[@mollfpr] Determine if we should create a regression test for this bug.
[@mollfpr] 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.

  1. Go to workspace chat.
  2. Submit a scan expense.
  3. While the receipt is scanning, go to Search.
  4. Verify that the 'Scanning...' message is displayed on the Merchant and Total fields
  5. After the receipt finishes scanning return back to the Search page
  6. Verify that the scan result is displayed on the Merchant and Total fields instead of the 'Scanning...' message
  7. 👍 or 👎

@JmillsExpensify
Copy link

$250 approved for @mollfpr

@luacmartins
Copy link
Contributor

We'll add tests as part of the project wrap up, so no need to do that now.

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. Engineering External Added to denote the issue can be worked on by a contributor Internal Requires API changes or must be handled by Expensify staff Weekly KSv2
Projects
Archived in project
Development

No branches or pull requests