-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Workspace - App crashed when send attachment offline and delete workspace from other device #41573
Comments
Triggered auto assignment to @iwiznia ( |
Triggered auto assignment to @lschurr ( |
👋 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:
|
@lschurr 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. |
We think this issue might be related to the #collect project. |
Production RPReplay_Final1714737209.MP4 |
ProposalPlease re-state the problem that we are trying to solve in this issue.Crash issue no longer happens on latest main, but we have another issue is loading infinity Screen.Recording.2024-05-03.at.19.42.10.movWhat is the root cause of that problem?We have 2 issues: Issue 1: After delete workspace the function loadOlderChats has trigger call infinity due to the report action is empty and FlatList trigger call onEndReached Issue 2: At this function we have filter out actionName = 'CREATE' and at this function we also filter out actionName = 'CLOSED' so sortedVisibleReportActions is empty and the UI is missing info What changes do you think we should make in order to solve the problem?Fix issue 1: onEndReached={() => {
if (!sortedVisibleReportActions.length || isLoadingOlderReportActions) {
return;
}
loadOlderChats();
}} Fix issue 2: + const isArchivedRoom = ReportUtils.isArchivedRoom(report);
const reportActions = useMemo(() => {
if (!sortedAllReportActions.length) {
return [];
}
+ const filteredReportActions = ReportActionsUtils.getContinuousReportActionChain(sortedAllReportActions, reportActionIDFromRoute);
+ if (isArchivedRoom) {
+ return sortedAllReportActions;
+ };
+ return filteredReportActions;
}, [isArchivedRoom, reportActionIDFromRoute, sortedAllReportActions]); What alternative solutions did you explore? (Optional)Update |
I don't think that solution makes sense. You should be able to go back and load all the older messages from an archived chat and the solution proposed will break that, no? Did anyone find the actual code that makes it crash? |
@izarutskaya why is there no desktop video? Also, desktop can't crash, so not sure what is happening in desktop... |
ok did the reproduction steps and not seeing a crash in web, seeing the loading older action issues described above (this is on staging, not main). |
Posted in slack here https://expensify.slack.com/archives/C01GTK53T8Q/p1714747609951879 |
I can reproduce the same issue of infinite loading in android, but not a crash. Don't have an ios to test the crash there. |
This comment was marked as outdated.
This comment was marked as outdated.
@izarutskaya I don't see any email in the issue. You should always include the email and other relevant data in the issue report (such as workspaceID, reportID, etc). That way I can retrieve logs for cases where I can't reproduce the issue like this one. |
@suneox did you see this?
|
I think this might be fixed by #41558. Would someone be able to test out that PR? My other theory is that the chat doesn't have a CREATED action as the last one for some reason so we don't know that we are at the end of the chat (see https://github.com/janicduplessis/Expensify-App/blob/10fbd6a53177685702bdfa90e102163506e263cf/src/pages/home/report/ReportActionsView.tsx#L320-L321). I have a proposal to have the backend return whether more data is available but it is more of a medium term fix (#41153). |
Proposal update@iwiznia I have update proposal to handle load all the older messages and prevent infinity trigger |
I think this part is wrong as it only works if the actions is of length 1 but if the other app adds a comment before deleting the workspace I still see the broken behavior. |
This update is specific for this issue to avoid regression, so if we still confuse we can check by condition if (isArchivedRoom) { return sortedAllReportActions } |
ProposalPlease re-state the problem that we are trying to solve in this issue.
What is the root cause of that problem?There is a bug in New messages loaded by For more context and debugging of this problem you can read through this chat in Slack. What changes do you think we should make in order to solve the problem?We need to fix What alternative solutions did you explore? (Optional) |
I already have a PR ready for the fix since I think this is a deploy blocker #41644, this is based on @roryabraham 's test fix #41598 |
Proposal updatedUpdate RCA explanation and simplify logic fix issue |
@iwiznia Tester login credentials (email) - applausetester+omq76@applause.expensifail.com. |
nice, let's move forward with #41644, that looks correct. I kicked off an AdHoc build of that so we can test. |
Verified that this is fixed and we didn't use any C+ services so I'm closing this out |
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: 1.4.70-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: https://expensify.testrail.io/index.php?/tests/view/4538783&group_by=cases:section_id&group_order=asc&group_id=306202
Email or phone of affected tester (no customers): applausetester+omq76@applause.expensifail.com
Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team
Action Performed:
Expected Result:
Error should be displayed
Actual Result:
App crashed when user sent attachment offline, deleted workspace from other device and returned online on main device
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Bug6469558_1714696989845.RPReplay_Final1714696916.mp4
View all open jobs on GitHub
The text was updated successfully, but these errors were encountered: