-
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-07-26] [$250] BUG: Failed distance request isn't cleaned up properly #42950
Comments
Triggered auto assignment to @mallenexpensify ( |
Job added to Upwork: https://www.upwork.com/jobs/~01b6ac9eda43aba0be |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @sobitneupane ( |
Triggered auto assignment to @CherylWalsh ( |
Hi @CherylWalsh, could we please have your expertise in coming up with a helpful error message for the user to see in this case. It's likely to happen if they create a distance request while offline, and then before they go back online an admin deletes the policy, or removes them from it. |
could I take the job please |
ProposalPlease re-state the problem that we are trying to solve in this issue.The transaction report remains with a RBR indicator, and the request is also still visible in the archived workspace chat What is the root cause of that problem?When clearing the transaction error in
Also the app's showing the generic back-end error as is, it should be updated to be more helpful as confirmed above. What changes do you think we should make in order to solve the problem?When clearing the transaction error, we can check that the transaction is having error while pending creation (ie. by checking that the transaction has errors and the transaction thread report has Line 5198 in 0cb2dc0
Here're the summary list of items:
And a few other caveats/conditions and implementation details for the different deletion, we can look into the For the back-end error message, we have the suggestion here to map the back-end specific error to front-end error translation key. This can be easily accomplished by transforming the error here, after getting the list of errors, we check if it contains an error with "Unexpected error submitting this expense. Please try again later. The workspace is no longer accessible. Please try again on a different workspace." message, if yes, swap it with an error translation key that we defined like What alternative solutions did you explore? (Optional)Aside from using |
Proposal updated to add some more details |
@CherylWalsh 👀 on the above plz.
@sobitneupane 👀 on @dominictb 's proposal above. @goldenbear101 , plz review CONTRIBUTING.md if you'd like to contribute to the program. Thx |
Proposal Please re-state the problem that we are trying to solve in this issue. The issue at hand is that the transaction report remains with a Retryable Blocked Request (RBR) indicator, and the request is still visible in the archived workspace chat after an error is dismissed. Root Cause Proposed Changes
Backend:
FRONTEND: // Display the translated error message Alternative Solutions By implementing these changes, the failed transaction requests will be properly cleaned up, improving the user experience and ensuring the application state is correctly maintained. |
@sobitneupane , 👀 on the proposals above plz |
I hope it's okay that I used AI to confirm my synopsis. I'm asking because I am new, If anything is needed to be cleared I would be more than happy to elaborate. |
Thanks for the proposal @dominictb
I believe we can add a new parameter to determine whether to make api request or not.
How are we handling other server returned error/messages in the app? Do we return translation key? Could you please provide more details about alternative solutions? |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
I don't think we should use the For the errors, the backend is currently returning a descriptive error message. Maybe we could check for the exact error message, and then swap it out for a translation key on the frontend somehow? Would that work? That would be easiest and fastest. The error thrown from the backend is deep in a tree of functions so it would be kind of tricky to return a translation key. I could make it work, but would prefer not to. |
Waiting for update. |
PR will be ready in a few hours (at most)! |
We had a delay because I suggested using a new pattern in an attempt to improve the error message, but that had to get reviewed by the team and it was not approved. Now I'm requesting that @dominictb removes the error message swapping from the PR and we merge the rest of it. |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.9-5 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-07-26. 🎊 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:
|
Contributor: @dominictb paid $250 via Upwork @sobitneupane plz complete the BZ checklist above. |
Comment for similar issue : #34087 (comment)
Not required.
Yes.
|
Regression Test Proposal
Do we agree 👍 or 👎 |
$250 approved for @sobitneupane |
Thanks @sobitneupane. Test case created |
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: main
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers): applausetester+kh300501@applause.expensifail.com
Logs: 88c4715bea025f6f-SIN
Expensify/Expensify Issue URL: https://github.com/Expensify/Expensify/issues/400806#top
Issue reported by: @neil-marcellini
Slack conversation:
Action Performed:
Expected Result:
The failed request should disappear completely after the error is dismissed. The transaction report should be deleted and the request should be removed from the workspace chat. Everything needs to be cleaned up. The user can get navigated back the the archived workspace chat, or something like that.
We should also probably improve the error message, and have it translated vs only in English from the backend. Requesting copy now.
Actual Result:
The transaction report remains with a RBR indicator, and the request is also still visible in the archived workspace chat
Workaround:
Sign out and back in to clear all optimistic/failure data
Platforms:
Which of our officially supported platforms is this issue occurring on?
All
Screenshots/Videos
335710534-aaa87b61-51d5-420e-bad6-1cb41c493858.mov
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @sobitneupaneThe text was updated successfully, but these errors were encountered: