-
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
[Due for payment 2025-02-27] [$250] Workspace - Inconsistent back navigation when clicking app back button #55196
Comments
Triggered auto assignment to @maddylewis ( |
ProposalPlease re-state the problem that we are trying to solve in this issue.Workspace - Inconsistent back navigation when clicking app back button What is the root cause of that problem?We are using normal navigate when we click 'go to workspace' button App/src/pages/ReportDetailsPage.tsx Lines 510 to 515 in 12f4847
And call App/src/pages/workspace/WorkspaceInitialPage.tsx Lines 399 to 408 in 12f4847
What changes do you think we should make in order to solve the problem?We should update type of this navigate to type
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?NA What alternative solutions did you explore? (Optional)OR we can add App/src/pages/ReportDetailsPage.tsx Lines 510 to 515 in 12f4847
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job. |
🚨 Edited by proposal-police: This proposal was edited at 2025-01-16 16:11:04 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.Inconsistent back navigation when clicking app back button What is the root cause of that problem?We did not send App/src/pages/ReportDetailsPage.tsx Lines 510 to 514 in c0f5173
So, when we go back from
The latest route is App/src/libs/Navigation/dismissModal.ts Line 19 in 4ffbd42
What changes do you think we should make in order to solve the problem?To fix this issue, we need to check if the navigation goes to FULL_SCREEN_NAVIGATOR, followed by SETTINGS.WORKSPACES, and then SCREENS.REPORT. If so, it indicates that we are on the report details page. With this approach, we don't need to check anything when navigating to the workspace. This is a global fix
Update to: const state = navigationRef.current?.getRootState() as State<RootStackParamList>;
const shouldPopHome =
state.routes?.length >= 3 &&
state.routes.at(-1)?.name === NAVIGATORS.FULL_SCREEN_NAVIGATOR &&
state.routes.at(-2)?.name === SCREENS.SETTINGS.WORKSPACES &&
state.routes.at(-3)?.name === SCREENS.REPORT &&
getTopmostBottomTabRoute(state)?.name === SCREENS.SETTINGS.ROOT;
if (shouldPopHome) {
Navigation.resetToHome();
navigationRef.goBack();
Navigation.navigate(ROUTES.REPORT_WITH_ID_DETAILS.getRoute(`${currentUserPolicyExpenseChat?.reportID ?? CONST.DEFAULT_NUMBER_ID}`));
} else {
Navigation.dismissModal();
} POCScreen.Recording.2025-01-14.at.23.03.58.mp4What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?This is a UI bug and does not require testing. What alternative solutions did you explore? (Optional)Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job. |
Job added to Upwork: https://www.upwork.com/jobs/~021879341293709833562 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @rojiphil ( |
Thanks for your proposals.
@huult What issue will occur on using
@daledah Using I think this is little tricky to solve as it could easily lead to regressions. Can you both please share a test branch based on your proposals to demonstrate that it works? Thanks. |
If we use my solution, we don’t need to add backTo for each case. It’s safer because there’s no worry about missing a case. Here is my test branch Test branchHere is the POC in my proposal Screen.Recording.2025-01-14.at.23.03.58.mp4
I updated the proposal to remove this |
@rojiphil, @maddylewis Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
Will review again today with the test branches. |
Sorry for the delay here and thanks for sharing the test branches. I tested and it seems to work the same. @huult I think going with the @daledah Why is there a need to |
@rojiphil Yes, my solution is a global fix because it eliminates the need to change or add backTo in the navigation. If we forget to include it, the issue will occur. Additionally, if we add new navigation in the future and forget or are unaware that we need to add backTo, the issue will happen again. I believe this highlights the distinct advantage of using my approach. |
we added |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
@rojiphil, @maddylewis Eep! 4 days overdue now. Issues have feelings too... |
@huult Adding |
@rojiphil @maddylewis this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks! |
Triggered auto assignment to @neil-marcellini, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
Yeah I agree. We shouldn't use the main solution with UP because the action doesn't match the definition here. backTo makes sense. App/contributingGuides/NAVIGATION.md Line 13 in 59a07d6
|
📣 @daledah 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app! Offer link |
@rojiphil, @neil-marcellini, @maddylewis, @daledah Whoops! This issue is 2 days overdue. Let's get this updated quick! |
I'll open PR soon |
@daledah - can you provide an update on the status of the PR? thanks! |
@maddylewis PR is actively been worked upon with the latest updates today. Next step is a review from my end which I intend to pick up tomorrow my day. |
This comment has been minimized.
This comment has been minimized.
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.2-1 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 2025-02-27. 🎊 For reference, here are some details about the assignees on this issue:
|
@rojiphil @maddylewis @rojiphil The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button] |
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: v9.0.83-5
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: N/A
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause Internal Team
Device used: MacOS Chrome, Desktop
App Component: Other
Action Performed:
Expected Result:
User should be navigated back to workspace chat details page the same way as it does for browser back button
Actual Result:
User is navigated back to workspace list page
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6713719_1736841131876.Screen_Recording_2025-01-14_at_10.44.03_in_the_morning.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @maddylewisThe text was updated successfully, but these errors were encountered: