Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.52k stars 2.87k forks source link

[HOLD] [$250] [Dupe detection] Tax field does not show the "Default" label on the confirmation page #47975

Open IuliiaHerets opened 2 months ago

IuliiaHerets commented 2 months ago

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.24-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:

Precondition:

  1. Go to staging.new.expensify.com
  2. Go to workspace chat.
  3. Submit two same distance expenses with the same distance rate that has tax rate and tax reclaimable on.
  4. Go to transaction thread of any submitted expense.
  5. Note that Tax field has the "Default" label.
  6. Click Review duplicates.
  7. Click Keep this on (any).
  8. Proceed to confirmation page.

Expected Result:

Tax field will show the "Default" label on the confirmation page.

Actual Result:

Tax field does not show the "Default" label on the confirmation page and instead shows "None"

Workaround:

Unknown

Platforms:

Screenshots/Videos

https://github.com/user-attachments/assets/ea6e4514-e527-4b48-9f17-21a88c6c7d21

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~017284a9effe70faa8
  • Upwork Job ID: 1828590697351581643
  • Last Price Increase: 2024-10-26
melvin-bot[bot] commented 2 months ago

Triggered auto assignment to @stephanieelliott (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 commented 2 months ago

We think that this bug might be related to #wave-control

IuliiaHerets commented 2 months ago

@stephanieelliott 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 commented 2 months ago

Proposal

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

Dupe detect - Tax field does not show the "Default" label on the confirmation page

What is the root cause of that problem?

            const comment = compareResult.change.description?.find((d) => d?.comment === data.value);
            setReviewDuplicatesKey({description: data.value, comment});

Test Branch

What alternative solutions did you explore? (Optional)


Alternatively we can store the comment object with updated comment instead of description text:

https://github.com/Expensify/App/blob/0c8455280c738a5db596f34409a0a3177e682e7f/src/libs/TransactionUtils/index.ts#L987-L992

NOTE: We also need to make changes in few other files. The changes are bit similar to solution above. Please checkout the text branch below for a better understanding.

Test Branch - Alternative Solution

Result

https://github.com/user-attachments/assets/2d8a009f-9b87-4cb3-a560-923d3882ae6d

stephanieelliott commented 2 months ago

updated the repro steps slightly -- actual result shows None instead of the expected default rate.

melvin-bot[bot] commented 2 months ago

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

melvin-bot[bot] commented 2 months ago

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

trjExpensify commented 2 months ago

and another one! CC: @dylanexpensify @pecanoro @parasharrajat @kubabutkiewicz

pecanoro commented 2 months ago

@alitoshmatov Could you review the proposals when you have some time?

parasharrajat commented 2 months ago

I can do that @pecanoro if needed.

pecanoro commented 2 months ago

Putting a HOLD here for now since it seems to be the same as https://github.com/Expensify/App/issues/47974

Krishna2323 commented 2 months ago

@pecanoro, I have proposals for both issues, and I can assure you that they are different. In this issue, we aren't persisting all the properties of the comment object, whereas in issue #47974, the comparison of the comment.comment string is incorrect.

I think we can remove the hold.

pecanoro commented 2 months ago

I still think we should wait since the proposals are really similar, and they will need to be updated accordingly.

melvin-bot[bot] commented 2 months ago

@pecanoro, @stephanieelliott, @alitoshmatov Huh... This is 4 days overdue. Who can take care of this?

stephanieelliott commented 1 month ago

Still holding on https://github.com/Expensify/App/issues/47974

stephanieelliott commented 1 month ago

Still holding on https://github.com/Expensify/App/issues/47974

pecanoro commented 1 month ago

Still holding

stephanieelliott commented 1 month ago

Still holding on https://github.com/Expensify/App/issues/47974

stephanieelliott commented 1 month ago

Im not able to reproduce this anymore -- can anyone else repro?

Krishna2323 commented 1 month ago

@stephanieelliott, issue is still reproducible.

https://github.com/user-attachments/assets/cd6d5ba0-28ea-4d9e-9afc-f59777b4f7c5

stephanieelliott commented 3 weeks ago

Ok @Krishna2323 can you make any necessary updates to your proposal, then let us know when it's ready so @alitoshmatov can review?

stephanieelliott commented 3 weeks ago

Bump on the above @Krishna2323, did still want to work on this?

Krishna2323 commented 3 weeks ago

@stephanieelliott, I will update my proposal/test branch today.

stephanieelliott commented 2 weeks ago

Hey @Krishna2323 have you had a chance to update the proposal?

Krishna2323 commented 2 weeks ago

@stephanieelliott sorry for the delay, I have updated the main solution's test branch. @alitoshmatov can start reviewing.

@alitoshmatov Let me know if you need a test branch for alternative solution too.

stephanieelliott commented 1 week ago

Hey @alitoshmatov can you review the updated proposal? https://github.com/Expensify/App/issues/47975#issuecomment-2308874978

stephanieelliott commented 1 week ago

Hey @alitoshmatov can you review the updated proposal? https://github.com/Expensify/App/issues/47975#issuecomment-2308874978

Bump @alitoshmatov

melvin-bot[bot] commented 1 week ago

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

melvin-bot[bot] commented 6 days ago

@pecanoro, @stephanieelliott, @alitoshmatov Whoops! This issue is 2 days overdue. Let's get this updated quick!

pecanoro commented 6 days ago

I am going to add the HOLD again until this one is merged since it will likely create conflicts: https://github.com/Expensify/App/pull/48958