Skip to content

[Due for payment 2025-08-20] [$250] Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags #66915

Closed

Description

@m-natarajan

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: 9.1.84-2
Reproducible in staging?: Y
Reproducible in production?: Y
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
Expensify/Expensify Issue URL:
Issue reported by: @dukenv0307
Slack conversation (hyperlinked to channel name): #Expensify Bugs

Action Performed:

  1. Create a workspace with the Tags feature enabled
  2. Navigate to the Tags page
  3. Click the Import button
  4. Choose Multi-level Tags
  5. Select a file to import
  6. Reload the page
  7. Click the back button in the header on RHP

Expected Result:

The app should navigate to the previous page.

Actual Result:

The modal is dismissed instead of navigating back.

Workaround:

Unknown

Platforms:

Select the officially supported platforms where the issue was reproduced:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop
Platforms Tested: On which of our officially supported platforms was this issue tested:
  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence
Screen.Recording.2025-07-23.at.04.20.47.mov
Recording.1441.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021948420784647349182
  • Upwork Job ID: 1948420784647349182
  • Last Price Increase: 2025-07-24
Issue OwnerCurrent Issue Owner: @garrettmknight

Activity

  1. added
    Daily
    Bug
    on Jul 22, 2025
  2. melvin-bot commented on Jul 22, 2025

    @melvin-bot

    Triggered auto assignment to @garrettmknight (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

  3. m-natarajan commented on Jul 22, 2025

    @m-natarajan
    Author

    Proposal by @dukenv0307

    Proposal

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

    After reloading the page, the header back button dismiss the modal

    What is the root cause of that problem?

    We handle back button here

    <HeaderWithBackButton
    title={translate('workspace.tags.importTags')}
    onBackButtonPress={() => Navigation.goBack(backTo)}

    But we don't add backTo when clicking the import button here

    if (spreadsheet?.isImportingMultiLevelTags) {
    return ROUTES.WORKSPACE_MULTI_LEVEL_TAGS_IMPORT_SETTINGS.getRoute(policyID);
    }

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

    We should add the default value as WORKSPACE_TAGS_IMPORT

        <HeaderWithBackButton
            title={translate('workspace.tags.importTags')}
            onBackButtonPress={() => Navigation.goBack(backTo ?? ROUTES.WORKSPACE_TAGS_IMPORT.getRoute(policyID))}
        />
    

    Or we can add the backTo as WORKSPACE_TAGS_IMPORT

        if (spreadsheet?.isImportingMultiLevelTags) {
            return ROUTES.WORKSPACE_MULTI_LEVEL_TAGS_IMPORT_SETTINGS.getRoute(policyID, ROUTES.WORKSPACE_TAGS_IMPORT.getRoute(policyID));
        }
    

    if (spreadsheet?.isImportingMultiLevelTags) {
    return ROUTES.WORKSPACE_MULTI_LEVEL_TAGS_IMPORT_SETTINGS.getRoute(policyID);
    }

    What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

    None

    What alternative solutions did you explore? (Optional)

  4. samranahm commented on Jul 22, 2025

    @samranahm
    Contributor

    Proposal

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

    Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags

    What is the root cause of that problem?

    We get the backTo route from route and use that here

    onBackButtonPress={() => Navigation.goBack(backTo)}

    • But backTo remain undefined regardless we refresh the page or not, and only Navigation.goBack work to take us to previous page but once we refresh the page, Navigation state resets and pressing back button close the model because there is no fallBack route

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

    We should explicitly add a fallBack route from ROUTES that we prefer to use and remove backTo

        title={translate('workspace.tags.importTags')}
        onBackButtonPress={() => Navigation.goBack(ROUTES.WORKSPACE_TAGS_IMPORT.getRoute(policyID))}

    like we did here

    <HeaderWithBackButton
    title={translate('workspace.tags.importTags')}
    onBackButtonPress={() => Navigation.goBack(ROUTES.WORKSPACE_MULTI_LEVEL_TAGS_IMPORT_SETTINGS.getRoute(policyID))}
    />

    What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

    N/A

    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.

  5. added
    External
    on Jul 24, 2025
  6. changed the title [-]Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags[/-] [+][$250] Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags[/+] on Jul 24, 2025
  7. melvin-bot commented on Jul 24, 2025

    @melvin-bot
  8. added
    Help Wanted
    on Jul 24, 2025
  9. melvin-bot commented on Jul 24, 2025

    @melvin-bot

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

  10. jayeshmangwani commented on Jul 28, 2025

    @jayeshmangwani
    Contributor

    @dukenv0307 's proposal #66915 (comment) looks good of onBackButtonPress navigating to WORKSPACE_TAGS_IMPORT - let's move forward with it.

    🎀 👀 🎀 C+ reviewed

  11. melvin-bot commented on Jul 28, 2025

    @melvin-bot

    Triggered auto assignment to @neil-marcellini, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

  12. 9 remaining items

  13. added
    Awaiting Payment
    on Aug 13, 2025
  14. changed the title [-][$250] Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags[/-] [+][Due for payment 2025-08-20] [$250] Clicking the back button dismisses modal instead of navigating to the previous page after importing multi-level tags[/+] on Aug 13, 2025
  15. removed
    Reviewing
    on Aug 13, 2025
  16. melvin-bot commented on Aug 13, 2025

    @melvin-bot

    Reviewing label has been removed, please complete the "BugZero Checklist".

  17. melvin-bot commented on Aug 13, 2025

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.93-7 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-08-20. 🎊

    For reference, here are some details about the assignees on this issue:

  18. melvin-bot commented on Aug 13, 2025

    @melvin-bot

    @jayeshmangwani / @dukenv0307 @garrettmknight 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]

  19. added
    Daily
    and removed
    Weekly
    on Aug 20, 2025
  20. jayeshmangwani commented on Aug 20, 2025

    @jayeshmangwani
    Contributor

    BugZero Checklist:

    • [Contributor] Classify the bug:
    Bug classification

    Source of bug:

    • 1a. Result of the original design (eg. a case wasn't considered)
    • 1b. Mistake during implementation
    • 1c. Backend bug
    • 1z. Other:

    Where bug was reported:

    • 2a. Reported on production (eg. bug slipped through the normal regression and PR testing process on staging)
    • 2b. Reported on staging (eg. found during regression or PR testing)
    • 2d. Reported on a PR
    • 2z. Other:

    Who reported the bug:

    • 3a. Expensify user
    • 3b. Expensify employee
    • 3c. Contributor
    • 3d. QA
    • 3z. Other:
    • [Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.

      Link to comment: [Multi-tags] Add ability to partially edit and fully import multi-level tags #62467

    • [Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.

      Link to discussion: N/A

    • [Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.

    Regression Test Proposal

    1. Create a workspace with the Tags feature enabled
    2. Navigate to the Tags page
    3. Click the Import button
    4. Choose Multi-level Tags
    5. Select a file to import
    6. Reload the page
    7. Click the back button in the header on RHP
    8. Verify that: The app should navigate to the previous page.

    Do we agree 👍 or 👎

  21. melvin-bot commented on Aug 20, 2025

    @melvin-bot

    Payment Summary

    Upwork Job

    BugZero Checklist (@garrettmknight)

    • I have verified the correct assignees and roles are listed above and updated the necessary manual offers
    • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants/1948420784647349182/hired)
    • I have verified the PR was not reverted
    • I have applied any discounts due to bugs/regressions introduced by this PR
    • I have paid out the Upwork contracts or cancelled the ones that are incorrect
    • I have verified the payment summary above is correct
  22. trjExpensify commented on Aug 21, 2025

    @trjExpensify
    Contributor

    Confirming payment summary here is correct.

  23. twisterdotcom commented on Aug 27, 2025

    @twisterdotcom
    Contributor

    @jayeshmangwani has submitted payment for this report on ND here.

    SO: https://stackoverflowteams.com/c/expensify/questions/7582

    Zapier Logs Run ID: 00040eee-36e0-a5ea-d984-136679b44561
  24. quinthar commented on Sep 7, 2025

    @quinthar
    Contributor

    $250 approved to @dukenv0307

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentBugDailyExternal

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions