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] [HOLD for payment 2024-02-15] [HOLD FOR PAYMENT: 15th Feburary] [$500] IOU - Payment option reverts back to 'Pay with Expensify' #36066

Closed
3 of 6 tasks
lanitochka17 opened this issue Feb 7, 2024 · 30 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 Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors

Comments

@lanitochka17
Copy link

lanitochka17 commented Feb 7, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 1.4.38-1
Reproducible in staging?: Y
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): [email protected]
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:

Action Performed:

  1. Create an IOU in workspace chat
  2. Change payment option to 'Pay elsewhere'
  3. Click on the IOU preview component

Expected Result:

Payment option on the header should be 'Pay elsewhere'

Actual Result:

Payment option on the header and IOU preview component of the main report reverts back to 'Pay with Expensify'

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

Bug6370785_1707331911006.iou_ljlj.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0153ee13375ff6a485
  • Upwork Job ID: 1755559026447237120
  • Last Price Increase: 2024-02-08
@lanitochka17 lanitochka17 added the DeployBlockerCash This issue or pull request should block deployment label Feb 7, 2024
Copy link
Contributor

github-actions bot commented Feb 7, 2024

👋 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.

Copy link

melvin-bot bot commented Feb 7, 2024

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

@lanitochka17
Copy link
Author

We think that this bug might be related to #vip-bills
CC @davidcardoza

@ishpaul777
Copy link
Contributor

ishpaul777 commented Feb 7, 2024

most probably related to #33866

@mkhutornyi
Copy link
Contributor

mkhutornyi commented Feb 7, 2024

Proposal

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

IOU - Payment option reverts back to 'Pay with Expensify'

What is the root cause of that problem?

Issue caused by different sorting logic here:

// Put the preferred payment method to the front of the array, so it's shown as default
if (paymentMethod) {
return buttonOptions.sort((method) => (method.value === paymentMethod ? 0 : 1));
}

Originally, _.sortBy was used.
returning 0 differs logic between _.sortBy (before TS migration) and native array .sort (after TS migration)

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

fix return value so if we wanna put front, return -1
like this:
buttonOptions.sort((method) => (method.value === paymentMethod ? -1 : 0));

@hoangzinh
Copy link
Contributor

cc @ZhenjaHorbach ^

@ZhenjaHorbach
Copy link
Contributor

cc @ZhenjaHorbach ^

Oh, sorry

I'll get to work on PR now

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Hourly KSv2 labels Feb 8, 2024
@Julesssss Julesssss assigned Julesssss and unassigned johnmlee101 Feb 8, 2024
@Julesssss Julesssss added Daily KSv2 Weekly KSv2 and removed Weekly KSv2 DeployBlockerCash This issue or pull request should block deployment labels Feb 8, 2024
@Julesssss Julesssss added the External Added to denote the issue can be worked on by a contributor label Feb 8, 2024
Copy link

melvin-bot bot commented Feb 8, 2024

Job added to Upwork: https://www.upwork.com/jobs/~0153ee13375ff6a485

@melvin-bot melvin-bot bot changed the title IOU - Payment option reverts back to 'Pay with Expensify' [$500] IOU - Payment option reverts back to 'Pay with Expensify' Feb 8, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Feb 8, 2024
Copy link

melvin-bot bot commented Feb 8, 2024

Current assignee @ishpaul777 is eligible for the External assigner, not assigning anyone new.

@melvin-bot melvin-bot bot removed the Weekly KSv2 label Feb 8, 2024
@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Daily KSv2 labels Feb 8, 2024
@melvin-bot melvin-bot bot changed the title [HOLD FOR PAYMENT: 15th Feburary] [$500] IOU - Payment option reverts back to 'Pay with Expensify' [HOLD for payment 2024-02-15] [HOLD FOR PAYMENT: 15th Feburary] [$500] IOU - Payment option reverts back to 'Pay with Expensify' Feb 8, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Feb 8, 2024
Copy link

melvin-bot bot commented Feb 8, 2024

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

Copy link

melvin-bot bot commented Feb 8, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.38-6 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-15. 🎊

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

  • @ishpaul777 requires payment (Needs manual offer from BZ)

Copy link

melvin-bot bot commented Feb 8, 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:

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

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Feb 12, 2024
@melvin-bot melvin-bot bot changed the title [HOLD for payment 2024-02-15] [HOLD FOR PAYMENT: 15th Feburary] [$500] IOU - Payment option reverts back to 'Pay with Expensify' [HOLD for payment 2024-02-19] [HOLD for payment 2024-02-15] [HOLD FOR PAYMENT: 15th Feburary] [$500] IOU - Payment option reverts back to 'Pay with Expensify' Feb 12, 2024
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:

  • @ishpaul777 requires payment (Needs manual offer from BZ)

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:

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

@MitchExpensify
Copy link
Contributor

Reminder set

Please apply to this job: https://www.upwork.com/jobs/~0153ee13375ff6a485. @mkhutornyi + @ishpaul777

@melvin-bot melvin-bot bot added Daily KSv2 Overdue and removed Weekly KSv2 labels Feb 15, 2024
Copy link

melvin-bot bot commented Feb 19, 2024

Payment Summary

Upwork Job

BugZero Checklist (@MitchExpensify)

  • 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/1755559026447237120/hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@ishpaul777
Copy link
Contributor

ishpaul777 commented Feb 19, 2024

  • [@ishpaul777] The PR that introduced the bug has been identified. Link to the PR:

#33866

  • [@ishpaul777] 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/33866/files#r1494729357

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

Not required.

  • [@ishpaul777] Determine if we should create a regression test for this bug.

I dont have strong feeling whether we need one or no, this was just a syntax difference between lodash sortBy and Array.sort

  • [@ishpaul777] 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.
    Steps in issue Description looks good if we decide to create a regression test.

Action Performed:

  1. Create an IOU in workspace chat
  2. Change payment option to 'Pay elsewhere'
  3. Click on the IOU preview component

Expected Result:

Payment option on the header should be 'Pay elsewhere'

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Feb 19, 2024
Copy link

melvin-bot bot commented Feb 23, 2024

@Julesssss, @MitchExpensify, @ishpaul777 Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@MitchExpensify
Copy link
Contributor

@ishpaul777
Copy link
Contributor

Thanks @MitchExpensify, I have accepted the offer!

@MitchExpensify
Copy link
Contributor

Paid and contracts ended - Thanks every one!

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 Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors
Projects
None yet
Development

No branches or pull requests

8 participants