Skip to content
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

[$250] Deeplink – Previous conversation opens for a moment when navigate via non-existing link #39914

Closed
4 of 6 tasks
izarutskaya opened this issue Apr 9, 2024 · 21 comments
Closed
4 of 6 tasks
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause Weekly KSv2

Comments

@izarutskaya
Copy link

izarutskaya commented Apr 9, 2024

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:**v1.4.61-0
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/4480382
Email or phone of affected tester (no customers): ponikarchuks+68424@gmail.com
Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team

Action Performed:

  1. Go to https://staging.new.expensify.com/
  2. Log in.
  3. Open any chat
  4. Navigate via non-existing link https://staging.new.expensify.com/anything
  5. Go back using arrow
  6. Navigate via non-existing link https://staging.new.expensify.com/anything
    again

Expected Result:

“Hmm... it's not here” page opens when navigate via non-existing link

Actual Result:

Previous conversation opens for a moment and then “Hmm... it's not here” page when navigate via non-existing link

Workaround:

Can the user still use Expensify without this being fixed? Have you informed them of the workaround?

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug6442856_1712612314454.Previous_conversation_opens_for_a_moment_when_navigate_via_non-existing_link.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01dc60681d78995448
  • Upwork Job ID: 1777681979216637952
  • Last Price Increase: 2024-04-23
@izarutskaya izarutskaya added DeployBlockerCash This issue or pull request should block deployment Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Apr 9, 2024
Copy link

melvin-bot bot commented Apr 9, 2024

Triggered auto assignment to @mountiny (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

Copy link

melvin-bot bot commented Apr 9, 2024

Triggered auto assignment to @kevinksullivan (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

Copy link
Contributor

github-actions bot commented Apr 9, 2024

👋 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:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@izarutskaya
Copy link
Author

@kevinksullivan 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.

@mountiny mountiny added Daily KSv2 and removed DeployBlockerCash This issue or pull request should block deployment Hourly KSv2 labels Apr 9, 2024
@mountiny
Copy link
Contributor

mountiny commented Apr 9, 2024

This does not seem like a blocker to me, no detriment to user experience

Going to export this to see if some proposals can fix it though

@mountiny mountiny added the External Added to denote the issue can be worked on by a contributor label Apr 9, 2024
@melvin-bot melvin-bot bot changed the title Deeplink – Previous conversation opens for a moment when navigate via non-existing link [$250] Deeplink – Previous conversation opens for a moment when navigate via non-existing link Apr 9, 2024
Copy link

melvin-bot bot commented Apr 9, 2024

Job added to Upwork: https://www.upwork.com/jobs/~01dc60681d78995448

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Apr 9, 2024
Copy link

melvin-bot bot commented Apr 9, 2024

Triggered auto assignment to Contributor-plus team member for initial proposal review - @abdulrahuman5196 (External)

@ikevin127
Copy link
Contributor

Proposal

Please re-state the problem that we are trying to solve in this issue

Previous conversation opens for a moment when navigating to a non-existing URL (not found page).

What is the root cause of that problem?

The root cause comes from this logic within the ReportScreenIDSetter component.

What's happening exactly ?

The above-referenced useEffect logic sets the reportID of the last accessed report in the route params, before navigation to a non-existing page is initiated resulting in the not found page.

How does this happen ?

  1. The first if of the useEffect checks if route?.params?.reportID exists -> when navigating to a non-existing page, route?.params?.reportID will be undefined.
  2. The first if is skipped-> the second if comes into play and sets the reportID of the last accessed report in the route params -> this is why we're navigated to the last accessed report before we're shown the not found page.

What changes do you think we should make in order to solve the problem?

We have to delay the setting the last accessed reportID in the route params. To do this we can wrap the final if of the useEffect with InteractionManager.runAfterInteractions which adds just the right amount of delay, but still sets the last accessed reportID in the route params (this is crucial for maintaining the current logic).

Code changes:

    InteractionManager.runAfterInteractions(() => {
        if (!reportID) {
            return;
        }
        navigation.setParams({reportID: String(reportID)});
    });

By doing this we're basically delaying setting the last accessed reportID in the route params, which won't navigate to the report first -> allowing the not found page to be displayed. Upon closing (or going back) the not found page, the user will be navigated to the last accessed report since the call to set the last accessed reportID in the params was made (with delay).

This means we will see the loading skeleton in the central pane then the not found page, instead of seeing / opening the report and only after that seeing the not found page.

Videos (before / after)

MacOS: Chrome / Safari
Before After
before.mov
after.mov

@mountiny
Copy link
Contributor

mountiny commented Apr 9, 2024

Thanks! That looks good to me but curious for a review from @abdulrahuman5196 too. Thanks!

@ikevin127
Copy link
Contributor

abdulrahuman5196 from (Slack):

Hi Team, I will be working on lesser capacity for next 2 weeks. I will un-assign myself from issues if I am unable to handle. Also feel free to re-assign if you see any issue delayed because of me.

cc @mountiny

@abdulrahuman5196
Copy link
Contributor

abdulrahuman5196 commented Apr 11, 2024

Hi, I will work on this issue in my morning

@abdulrahuman5196
Copy link
Contributor

Checking now.

@abdulrahuman5196
Copy link
Contributor

I am not seeing this issue in staging. Let me know if i need to do anything else to repro.

Screen.Recording.2024-04-12.at.9.14.14.PM.mov

@ikevin127
Copy link
Contributor

Looks like the issue is gone, not reproducible anymore.
We can ask for a double-check from the testing team and close if confirmed.

@melvin-bot melvin-bot bot added the Overdue label Apr 15, 2024
@mountiny mountiny added retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause Weekly KSv2 and removed Daily KSv2 labels Apr 15, 2024
@melvin-bot melvin-bot bot removed the Overdue label Apr 15, 2024
@mountiny
Copy link
Contributor

waiting for a retest

Copy link

melvin-bot bot commented Apr 15, 2024

@kevinksullivan, @mountiny, @abdulrahuman5196 Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

Copy link

melvin-bot bot commented Apr 16, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

1 similar comment
Copy link

melvin-bot bot commented Apr 23, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

Copy link

melvin-bot bot commented Apr 23, 2024

@kevinksullivan @mountiny @abdulrahuman5196 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!

@melvin-bot melvin-bot bot added the Overdue label Apr 23, 2024
@mountiny
Copy link
Contributor

Waiitng for retest

@melvin-bot melvin-bot bot removed the Overdue label Apr 24, 2024
@kevinksullivan
Copy link
Contributor

Unable to reproduce, so I'm closing out!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause Weekly KSv2
Projects
None yet
Development

No branches or pull requests

5 participants