-
Notifications
You must be signed in to change notification settings - Fork 3k
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-06-06] [$500] [Workflows] Bank account and Authorized payer buttons displayed instead of Connect bank account #39947
Comments
Triggered auto assignment to @isabelastisser ( |
@isabelastisser 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 |
ProposalPlease re-state the problem that we are trying to solve in this issue.We see bank account and authorized payer options even when we haven't added bank account What is the root cause of that problem?We show
If this is false then we show Now when we click on connect bank account for the first time, we set a field inside of ACHaccount Lines 187 to 194 in 5b1dbea
So even when we do not complete the add bank account flow, we still set the value of And hence when we toggle the option, it takes data from Onyx as we have stored the value of Note : If we refresh the page then What changes do you think we should make in order to solve the problem?We should only set What alternative solutions did you explore? (Optional)N/A |
ProposalPlease re-state the problem that we are trying to solve in this issue.BA - Bank account and Authorized payer buttons displayed instead of Connect bank account What is the root cause of that problem?We display Bank account or Connect bank account based on this condition.
but here when we disable App/src/libs/actions/Policy.ts Line 732 in aed0bf0
What changes do you think we should make in order to solve the problem?We can define // const hasVBA = !!policy?.achAccount;
const hasVBA = !!policy?.achAccount?.bankAccountID; What alternative solutions did you explore? (Optional)We can also return the correct // achAccount: {reimburser: reimburserEmail},
achAccount: reimbursementChoice === CONST.POLICY.REIMBURSEMENT_CHOICES.REIMBURSEMENT_NO ? null : {reimburser: reimburserEmail}, or just set the reimburser not whole achAccount to null |
Job added to Upwork: https://www.upwork.com/jobs/~01ad1e7b394f8ced40 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @ishpaul777 ( |
ProposalPlease re-state the problem that we are trying to solve in this issue"Bank account" and "Authorized payer" buttons are displayed instead of "Connect bank account" after clicking the "Connect bank account" button and re-toggling "Make or track payments". What is the root cause of that problem?Everytime we toggle "Make or track payments", we call This was introduced by PR #39017, specifically for the scenario where a bank account is already added, in order to be able to change the Authorized payer while offline (optimistically). The problem with this is that in our case, we don't yet have a bank account added and because the Note When offline, the following buttons are always disabled:
The "Authorized payer" button is always enabled because we want to be able to change the Authorized payer even if we're offline, according to PR #39017. What changes do you think we should make in order to solve the problem?In order to maintain the functionality added by PR #39017 and also fix our issue, accounting for both flows (no BA added and with BA added) we have to perform the following changes:
const shouldShowBankAccount = !!bankAccountID && policy?.reimbursementChoice === CONST.POLICY.REIMBURSEMENT_CHOICES.REIMBURSEMENT_YES; which removes // 1
} else if (!!policy?.achAccount && !Policy.isCurrencySupportedForDirectReimbursement(policy?.outputCurrency ?? '')) { replacing // 2
newReimbursementChoice = CONST.POLICY.REIMBURSEMENT_CHOICES.REIMBURSEMENT_YES; removing the
Videos (without BA / with BA)MacOS: Chrome / Safari
|
@ishpaul777 please review the proposals above. Thanks! |
reviewing now 👀 |
Thanks for your proposals all! While all of the proposed solution works i lean of choosing solution from both @ahmedGaber93 and @ikevin127 because checking So i'd suggest we split up the contributor bounty 75% for contributor for implementation and 25% for the other contributor. 🎀 👀 🎀 C+ reviewed |
Triggered auto assignment to @tylerkaraszewski, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
But, shouldn’t we check for all the fields @ishpaul777 ? i guess for a bank account to be displayed we must validated that all the fields are present , my proposal mentions the same thing, what do you think ? |
hmm, but i dont think there will ever be a case when we have a bankAccountId without other fields or is it? 🤔 |
fair point you got not saying no, but why to leave any loophole, suppose if we delete bank account offline, do we clear all the fields optimistically? 🤔 |
okay good point, for safety i'd agree we can include a check if |
If nothing's set in stone yet, lemme go ask a few people to post a proposal here mentioning some other
You're correct ✅ |
Alright @ishpaul777 , thanks for considering |
yes, becuase your RCA was most detailed and easy to follow
i believe 2 only @ikevin127 and @ahmedGaber93 because the other fields are just to be on safe side, not required.
I know this is being said satirically but such comments are not necessary while on a public platform |
I was joking, pardon me - I just found the split situation hilarious considering we're talking about a $250 bounty 😅 Give this one to @ahmedGaber93, you have full consent to use my side of the solution -> just make sure to test it well (including w/ existing BA scenario). |
Great Thanks for voluntering, i only suggested the split to be fair to everyone |
@lakchote's decision was fair at this time. @ikevin127 if you found other complex issue in PR which make split not fair for you, don't let this stop you, you can move forward to complete it, and take the full bounty. |
@ikevin127 I've made and explained my decision based on facts discussed here.
With that being said, could you detail why a complex solution will need to be done? Is it because it'd require, according to you, extensive frontend changes? Optimizing the API command I'll dig more into it if there needs to be, as I have to handle an important issue that's breaking our
Let's wait for answer to @trjExpensify's comment here. |
Correct, and I did not have an issue with the split at that time. This was confusing to me and obviously required additional changes, outside of what was already agreed upon when the split reasoning went down. This is why I find it unfair to split the already small bounty, just because the other contributor had a 1-line contribution which in actuality was of little help to the final solution implemented (see updated proposal). I take responsability here for not communicating well enough as I should've communicated this earlier and better.
Big part of why the issue stagnated, at least on my part is cause I was confused with the reviewer's comment regarding the already approved loading spinner flow and a final decision from the rest of the team after their comment. Additionally, I also mentioned some possible BE related issues since @trjExpensify pointed out that one of the endpoint responses is too slow and could be improved. Besides this, while testing the PR I discovered other FE logic issues with the flow, especially when we have a BA added and we toggle "Make or track payments" which require additional changes to the current PR. Updated proposal
|
I have put the option to move forward here even though i was not aligned with it fully but then this comment made me think we still have this not fully functional even with the loader
|
@ikevin127 I will review updated proposal over the weekend |
@ikevin127 thank you for updating your proposal and taking the time to answer my questions. I didn't read your message that way. I totally understand your concern and frustration now, regarding the work involved in the loading spinner only to put it on hold at the final stage. |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.77-11 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-06-06. 🎊 For reference, here are some details about the assignees on 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:
|
No need to open a discussion or update the PR review checklist as this was an issue which could've been mitigated by thoroughly testing the feature both while online and offline, which is already a checkbox on the PR author / reviewer checklist.
Regression Test Proposal
Do we agree 👍 or 👎. |
Note: This issue's bounty should be increased to $500 as per this Slack post, since it was always |
Upwork job price has been updated to $500 |
I do agree. @isabelastisser I've increased the Upwork job price. |
The offers were sent in Upwork. All set! |
Offer accepted! Thanks! |
Offer accepted, thank you! |
This comment was marked as resolved.
This comment was marked as resolved.
nvm my last comment i got it confused with another issue |
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.61.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: https://expensify.testrail.io/index.php?/tests/view/4482904
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause - Internal Team
Action Performed:
Pre-requisite: user must be logged in
Expected Result:
"Connect bank account" button should be displayed
Actual Result:
"Bank account" and "Authorized payer" buttons are displayed instead of "Connect bank account"
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6443564_1712674706894.Lslh2115_1_.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @isabelastisserThe text was updated successfully, but these errors were encountered: