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

[Payment Due 09/16] [$250] Dupe detection - Merchant field shows (none) instead of blank when (none) is selected #46998

Closed
6 tasks done
IuliiaHerets opened this issue Aug 7, 2024 · 29 comments
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

@IuliiaHerets
Copy link

IuliiaHerets commented Aug 7, 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: v9.0.17-1
Reproducible in staging?: Y
Reproducible in production?: Y
Email or phone of affected tester (no customers): applausetester+kh050806@applause.expensifail.com
Issue reported by: Applause Internal Team

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to DM.
  3. Submit an expense with no merchant and description.
  4. Submit another expense with the same amount, and with merchant and description.
  5. Go to the transaction thread of the second expense (Step 4).
  6. Click Review duplicates.
  7. Click Keep this one (any).
  8. During the review, select (none) for Merchant and None for Description.
  9. Proceed to confirmation page.

Expected Result:

Merchant field should be empty since none is selected.

Actual Result:

Merchant field shows (none) when (none) is selected, while Description field is empty when None is selected.

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

Add any screenshot/video evidence

Bug6564736_1723051455589.20240808_011943.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0194455fbb3684c1f1
  • Upwork Job ID: 1823630303854706776
  • Last Price Increase: 2024-08-21
  • Automatic offers:
    • Krishna2323 | Contributor | 103626733
Issue OwnerCurrent Issue Owner: @eVoloshchak
@IuliiaHerets IuliiaHerets added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Aug 7, 2024
Copy link

melvin-bot bot commented Aug 7, 2024

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

@IuliiaHerets
Copy link
Author

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

@IuliiaHerets
Copy link
Author

@dylanexpensify 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

@Krishna2323
Copy link
Contributor

Krishna2323 commented Aug 7, 2024

Edited by proposal-police: This proposal was edited at 2023-10-11T18:10:00Z.

Proposal

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

Dupe detection - Merchant field shows (none) instead of blank when (none) is selected

What is the root cause of that problem?

In ReviewMerchant we are not checking if the merchant is merchant === CONST.TRANSACTION.PARTIAL_TRANSACTION_MERCHANT to consider it as empty.

!merchant
? {text: translate('violations.none'), value: ''}

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

Update the condition to:

    const options = useMemo(
        () =>
            compareResult.change.merchant?.map((merchant) =>
                !merchant || merchant === CONST.TRANSACTION.PARTIAL_TRANSACTION_MERCHANT
                    ? {text: translate('violations.none'), value: ''}
                    : {
                          text: merchant,
                          value: merchant,
                      },
            ),
        [compareResult.change.merchant, translate],
    );

What alternative solutions did you explore? (Optional)

Update the title prop in MoneyRequestView. We can create a variable for the updatedTransaction?.modifiedMerchant, just like we have merchantTitle.

title={updatedTransaction?.modifiedMerchant ?? merchantTitle}

To:

title={(updatedTransaction?.modifiedMerchant === CONST.TRANSACTION.PARTIAL_TRANSACTION_MERCHANT ? '' : updatedTransaction?.modifiedMerchant) ?? merchantTitle}

This is the same way we show empty merchant for a transaction when merchant is (none) so I think this is the more correct way fix this issue.

let merchantTitle = isEmptyMerchant ? '' : transactionMerchant;

@melvin-bot melvin-bot bot added the Overdue label Aug 12, 2024
@dylanexpensify
Copy link
Contributor

I believe we need to have something in for merchant, otherwise an error is thrown, so this isn't a bug

@Krishna2323
Copy link
Contributor

Merchant field shows (none) when (none) is selected, while Description field is empty when None is selected.

@dylanexpensify, merchant is only required in workspace chats, direct request to any user can be made without merchant so this is a valid bug. In the video below you can see that the merchant field is empty after creating the request, '(none)' is not shown.

@parasharrajat, I believe you have worked on this feature, can you please confirm this? 🙏🏻

Monosnap.screencast.2024-08-13.14-40-38.mp4

@dylanexpensify
Copy link
Contributor

Ah, good catch @Krishna2323

@parasharrajat
Copy link
Member

Looks like a valid bug to me as well.

@dylanexpensify dylanexpensify added the External Added to denote the issue can be worked on by a contributor label Aug 14, 2024
@melvin-bot melvin-bot bot changed the title Dupe detection - Merchant field shows (none) instead of blank when (none) is selected [$250] Dupe detection - Merchant field shows (none) instead of blank when (none) is selected Aug 14, 2024
Copy link

melvin-bot bot commented Aug 14, 2024

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

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

Forgot to hit external.

Copy link

melvin-bot bot commented Aug 14, 2024

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

Copy link

melvin-bot bot commented Aug 19, 2024

@eVoloshchak, @dylanexpensify Eep! 4 days overdue now. Issues have feelings too...

@melvin-bot melvin-bot bot added the Overdue label Aug 19, 2024
@Krishna2323
Copy link
Contributor

@eVoloshchak, friendly bump for review.

Copy link

melvin-bot bot commented Aug 21, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

@eVoloshchak
Copy link
Contributor

@Krishna2323's proposal LGTM, both solutions are equivalent, I think we should proceed with the main one (update condition in ReviewMerchant.tsx)

🎀👀🎀 C+ reviewed!

Copy link

melvin-bot bot commented Aug 21, 2024

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

Copy link

melvin-bot bot commented Aug 21, 2024

@Beamanator @eVoloshchak @dylanexpensify this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

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

melvin-bot bot commented Aug 21, 2024

📣 @Krishna2323 🎉 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 📖

@Krishna2323
Copy link
Contributor

@eVoloshchak PR ready for review ^

@Krishna2323
Copy link
Contributor

@eVoloshchak, friendly bump for the review :)

@dylanexpensify
Copy link
Contributor

pending deploy and regression

@melvin-bot melvin-bot bot removed the Weekly KSv2 label Sep 16, 2024
Copy link

melvin-bot bot commented Sep 16, 2024

This issue has not been updated in over 15 days. @Beamanator, @eVoloshchak, @dylanexpensify, @Krishna2323 eroding to Monthly issue.

P.S. Is everyone reading this sure this is really a near-term priority? Be brave: if you disagree, go ahead and close it out. If someone disagrees, they'll reopen it, and if they don't: one less thing to do!

@melvin-bot melvin-bot bot added the Monthly KSv2 label Sep 16, 2024
@Krishna2323
Copy link
Contributor

@Beamanator @eVoloshchak, there hasn't been any update from Melvin about the staging/production deployment, but I believe it's already deployed and has passed the regression period. I'm not completely sure though, could you please check? 🙏🏻

@Beamanator
Copy link
Contributor

Ooh yep i see your code in prod -

title={updatedMerchantTitle}

@Beamanator Beamanator added Awaiting Payment Auto-added when associated PR is deployed to production and removed Reviewing Has a PR in review labels Sep 25, 2024
@Beamanator Beamanator changed the title [$250] Dupe detection - Merchant field shows (none) instead of blank when (none) is selected [Payment Due 09/16] [$250] Dupe detection - Merchant field shows (none) instead of blank when (none) is selected Sep 25, 2024
@Beamanator
Copy link
Contributor

cc @dylanexpensify - looks like payment is due here - there was an automation problem 😓

@melvin-bot melvin-bot bot added Daily KSv2 and removed Monthly KSv2 labels Oct 1, 2024
@dylanexpensify
Copy link
Contributor

Payment summary:

Contributor: @Krishna2323 $250 via Upwork
Contributor+: @eVoloshchak $250 via NewDot

Please apply/request!

@melvin-bot melvin-bot bot added the Overdue label Oct 4, 2024
Copy link

melvin-bot bot commented Oct 4, 2024

@Beamanator, @eVoloshchak, @dylanexpensify, @Krishna2323 Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@dylanexpensify
Copy link
Contributor

Done

@JmillsExpensify
Copy link

$250 approved for @eVoloshchak

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
None yet
Development

No branches or pull requests

7 participants