-
Notifications
You must be signed in to change notification settings - Fork 3.2k
[$250] Fix replacing physical Expensify Card flow #61239
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
Comments
Current assignee @joekaufmanexpensify is eligible for the Bug assigner, not assigning anyone new. |
Job added to Upwork: https://www.upwork.com/jobs/~021917925085751646864 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @dominictb ( |
@dominictb Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
Pending proposals |
ProposalPlease re-state the problem that we are trying to solve in this issue.We have 3 problems:
What is the root cause of that problem?BUG 1: The BE doesn't return both the issued card message and the shipped card message BUG 2:
BUG 3: I can't reproduce this bug, I will ask the author to investigate this bug later What changes do you think we should make in order to solve the problem?In the scope of this issue, I will post a solution for bug 2 In ReportCardLostPage, we need to add a useEffect to reset validateCodeSent. We also applied this way on the issue new card flow
In
Bonus point, we can add a loading indicator while the API is processing What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?None What alternative solutions did you explore? (Optional)None |
@dominictb are you able to review the proposal? Looks good to me |
I can't reproduce the third issue either, can you @joekaufmanexpensify? We need both FE & BE fixes. @DylanDylann proposal LGTM 🎀👀🎀 C+ reviewed |
Triggered auto assignment to @roryabraham, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
I am happy to try again to see if I can reproduce it. Is there any data that would be helpful in the event I can reimburse it? I can share the result of the API call when I try and replace the card, but LMK if anything beyond that would be helpful. I want to ideally do it once as it takes a bit of time to reproduce. |
@joekaufmanexpensify It would be great if I got added to the #convert room to grab more details on this bug. That would help reproduce this issue easier. |
📣 @dominictb 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app! |
@joekaufmanexpensify First, could you please provide a video on how this bug happened? And if possible, please DM to me the response of RequestReplacementExpensifyCard API |
@joekaufmanexpensify Many thanks for your help. @mountiny The third problem also be a BE bug The third problem in this issue may be caused by RequestReplacementExpensifyCard is called twice The first API replaces the card successful Note that: the two above API have the same payload. It is the reason why the second API failed because the magic code was used twice Let's question why RequestReplacementExpensifyCard is called twice. It dues to the first API return the wrong format of onyxData ![]() the onyxData should be an array instead of an object. Because If onyxData is an object, this line will cause the error because forEach isn't a method of object
Then this catch block will be triggered and cause the second API to be called App/src/libs/Network/SequentialQueue.ts Line 162 in 3d6c64b
|
Summary
|
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Reproducible in staging?: Y
Reproducible in production?: Y
Issue reported by: @joekaufmanexpensify
Slack conversation (hyperlinked to channel name): #convert
Action Performed:
Prereq: Have the Expensify Card enabled with a non-test bank account (so you can issue physical Expensify Cards)
Expected Result:
Three different bugs here:
Actual Result:
The replace card issues happened both when replacing a card pending activation and with an already active card.
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Select the officially supported platforms where the issue was reproduced:
Screenshots/Videos
2025-04-30_18-00-57.mp4
2025-04-30_17-59-04.1.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @roryabrahamThe text was updated successfully, but these errors were encountered: