-
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 2023-09-07] [HOLD for payment 2023-09-06] [$1000] Request money: App Crashes when clicking UP key from keyboard after requesting money #26209
Comments
Triggered auto assignment to @kevinksullivan ( |
Bug0 Triage Checklist (Main S/O)
|
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open
|
Triggered auto assignment to @bondydaa ( |
ProposalPlease re-state the problem that we are trying to solve in this issue.Request money: App Crashes when clicking UP key from keyboard after requesting money What is the root cause of that problem?When press UP action, we will save draft and focus on previous message here: App/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js Lines 295 to 297 in 3f9f1e6
However, in this case, the previous message is not editable, which make our textInputRef is not set, but since the draft is saved. This condition will be trigger and make the crash.App/src/pages/home/report/ReportActionItem.js Line 161 in 3f9f1e6
What changes do you think we should make in order to solve the problem?We should update the logic of We should add this condition to our function canEditReportAction(reportAction) {
const isCommentOrIOU = reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.ADDCOMMENT || reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.IOU;
return (
reportAction.actorAccountID === currentUserAccountID &&
isCommentOrIOU &&
canEditMoneyRequest(reportAction) && // Returns true for non-IOU actions
!isReportMessageAttachment(lodashGet(reportAction, ['message', 0], {})) &&
// shouldn't show edit with created money report action
!ReportActionsUtils.isCreatedMoneyReportAction(reportAction) &&
!ReportActionsUtils.isDeletedAction(reportAction) &&
!ReportActionsUtils.isCreatedTaskReportAction(reportAction) &&
reportAction.pendingAction !== CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE
);
} function isCreatedMoneyReportAction(reportAction) {
const originalMessage = lodashGet(reportAction, 'originalMessage', {});
const isSendingMoney = originalMessage.type === CONST.IOU.REPORT_ACTION_TYPE.PAY && _.has(originalMessage, 'IOUDetails');
return reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.IOU && originalMessage && originalMessage.type === CONST.IOU.REPORT_ACTION_TYPE.CREATE || originalMessage.type === CONST.IOU.REPORT_ACTION_TYPE.SPLIT || isSendingMoney;
} What alternative solutions did you explore? (Optional)Keep the logic of the
const lastReportAction = _.find([...reportActions, parentReportAction], (action) => ReportUtils.canEditReportAction(action)) && !ReportActionsUtils.isCreatedMoneyReportAction(reportAction) |
ProposalPlease re-state the problem that we are trying to solve in this issue.App crashes on IOU report when click UP key from keyboard after requesting money What is the root cause of that problem?MoneyRequestPreview is not text-editable action but UP key is applied and trying to be in edit mode What changes do you think we should make in order to solve the problem?It doesn't make sense to change
So add one more condition: |
@hungvu193's alternative solution looks good. |
commented on #26209 asking for guidance |
@bondydaa I think @mountiny is on travel right now and not likely to answer soon. |
Job added to Upwork: https://www.upwork.com/jobs/~017bc5b54c670a647e |
Current assignee @kevinksullivan is eligible for the External assigner, not assigning anyone new. |
Current assignee @situchan is eligible for the External assigner, not assigning anyone new. |
📣 @situchan 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app! |
Offer accepted. Thank you |
I'm gonna demote this to NAB. While it isn't great that the App crashes, I think this is enough of an edge case that it won't affect most users. Besides, we also have a PR up which will likely be merged tomorrow. |
But it's bad that once crash happens, always crash even after refresh, until logout and re-login. I have PR ready |
🎯 ⚡️ Woah @situchan / @situchan, great job pushing this forwards! ⚡️ The pull request got merged within 3 working days of assignment, so this job is eligible for a 50% #urgency bonus 🎉
On to the next one 🚀 |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.58-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 2023-09-06. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
For reference, here are some details about the assignees on this issue:
As a reminder, here are the bonuses/penalties that should be applied for any External 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:
|
Thanks for help here @hungvu193 @situchan this was quite tricky thing to discover. |
@situchan fill out the checklist above when you get a chance. Thanks! |
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.59-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 2023-09-07. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
For reference, here are some details about the assignees on this issue:
As a reminder, here are the bonuses/penalties that should be applied for any External 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:
|
Paid out, closing. |
Upwork giving me the blank screen contract end bug, so I'll need to come back to this for you @situchan . |
@situchan in the meantime, can you complete the steps above? |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
Expected Result:
The app shouldn't be crashed
Actual Result:
The app crashes
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: v1.3.58-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):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Screenshare.-.2023-08-29.4_17_36.PM.mp4
Recording.1365.mp4
Expensify/Expensify Issue URL:
Issue reported by: @misgana96
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1693307519948199
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: