You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2025-12-04] [$250] Android - Workspace - "It´s not here" briefly seen after deleting workspace from "Overview" #73137
What changes do you think we should make in order to solve the problem?
We should update confirmDelete to navigate away FIRST using goBackFromInvalidPolicy()
And use InteractionManager.runAfterInteractions to delay the actual deleteWorkspace call until after the navigation completes (This will be deprecated soon, however, we haven't decided solution so we could go with requestIdleCallback or setTimeOut or any other ways to delay the action if needed)
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.
🚨 Edited by proposal-police: This proposal was edited at 2025-11-11 14:44:02 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
It's not here" briefly seen after deleting workspace from Overview
What is the root cause of that problem?
The logic for determining when to show the NotFound page has a flaw in the second return statement. Specifically, the condition (!shouldShowPolicy && (!isPendingDelete || prevIsPendingDelete)) incorrectly evaluates to true when a workspace has just been deleted.
When deletion completes: isPendingDelete = false and prevIsPendingDelete = true, so (!isPendingDelete || prevIsPendingDelete) becomes true, which triggers the NotFound page to show.
What changes do you think we should make in order to solve the problem?
We should fix the logic to use AND conditions instead of OR for the pending delete checks. This ensures the NotFound page only shows when the workspace is neither currently being deleted nor was just deleted.
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.
Immediately after deleting a workspace, the shouldShow value is still set to true because the condition (!shouldShowPolicy && (!isPendingDelete || prevIsPendingDelete)) evaluates to true as soon as the policy is updated for deletion.
changed the title [-]Android - Workspace - "It´s not here" briefly seen after deleting workspace from "Overview"[/-][+][$250] Android - Workspace - "It´s not here" briefly seen after deleting workspace from "Overview"[/+]on Oct 24, 2025
[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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Activity
melvin-bot commentedon Oct 21, 2025
Triggered auto assignment to @zanyrenney (
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.lorretheboy commentedon Oct 21, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
After deleting a workspace from the "More" menu on "Overview", an "It´s not here" page is briefly displayed, before landing on the workspaces list
What is the root cause of that problem?
The
confirmDeletefunction was callingdeleteWorkspaceimmediately, which optimistically set pendingAction: DELETE on the policyuseEffect was watching for the deletion to complete and only then navigating away
During this time, the
WorkspacePageWithSectionscomponent detected the policy was being deleted and showed the "not found" pageApp/src/pages/workspace/WorkspaceOverviewPage.tsx
Lines 220 to 226 in b38b008
App/src/pages/workspace/WorkspaceOverviewPage.tsx
Lines 240 to 250 in b38b008
What changes do you think we should make in order to solve the problem?
We should update
confirmDeleteto navigate away FIRST using goBackFromInvalidPolicy()And use
InteractionManager.runAfterInteractionsto delay the actual deleteWorkspace call until after the navigation completes (This will be deprecated soon, however, we haven't decided solution so we could go withrequestIdleCallbackorsetTimeOutor any other ways to delay the action if needed)App/src/pages/workspace/WorkspaceOverviewPage.tsx
Line 225 in b38b008
Update the useEffect to only handle showing the error modal if deletion fails (removed the navigation logic)
App/src/pages/workspace/WorkspaceOverviewPage.tsx
Lines 244 to 249 in b38b008
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.
samranahm commentedon Oct 21, 2025
🚨 Edited by proposal-police: This proposal was edited at 2025-11-11 14:44:02 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
It's not here" briefly seen after deleting workspace from Overview
What is the root cause of that problem?
The logic for determining when to show the NotFound page has a flaw in the second return statement. Specifically, the condition
(!shouldShowPolicy && (!isPendingDelete || prevIsPendingDelete))incorrectly evaluates totruewhen a workspace has just been deleted.When deletion completes:
isPendingDelete = falseandprevIsPendingDelete = true, so(!isPendingDelete || prevIsPendingDelete)becomestrue, which triggers the NotFound page to show.App/src/pages/workspace/WorkspacePageWithSections.tsx
Line 170 in 73a784d
What changes do you think we should make in order to solve the problem?
We should fix the logic to use AND conditions instead of OR for the pending delete checks. This ensures the NotFound page only shows when the workspace is neither currently being deleted nor was just deleted.
Change the return statement from
App/src/pages/workspace/WorkspacePageWithSections.tsx
Line 170 in 73a784d
To
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.
dmkt9 commentedon Oct 22, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
After deleting a workspace from the "More" menu on "Overview", an "It´s not here" page is briefly displayed, before landing on the workspaces list
What is the root cause of that problem?
FullPageNotFoundViewis rendered based on the value ofshouldShow:App/src/pages/workspace/WorkspacePageWithSections.tsx
Lines 201 to 208 in 09a7472
Immediately after deleting a workspace, the
shouldShowvalue is still set totruebecause the condition(!shouldShowPolicy && (!isPendingDelete || prevIsPendingDelete))evaluates totrueas soon as the policy is updated for deletion.App/src/pages/workspace/WorkspacePageWithSections.tsx
Lines 163 to 172 in 09a7472
On Android, even minor changes can trigger a re-render, which results in the "It’s not here" page being displayed.
What changes do you think we should make in order to solve the problem?
We should delay rendering the NotFound page until
prevPolicyis also no longer in a delete-pending state.App/src/pages/workspace/WorkspacePageWithSections.tsx
Lines 163 to 172 in 09a7472
What alternative solutions did you explore? (Optional)
NA
[-]Android - Workspace - "It´s not here" briefly seen after deleting workspace from "Overview"[/-][+][$250] Android - Workspace - "It´s not here" briefly seen after deleting workspace from "Overview"[/+]melvin-bot commentedon Oct 24, 2025
Job added to Upwork: https://www.upwork.com/jobs/~021981775013425327474
melvin-bot commentedon Oct 24, 2025
Triggered auto assignment to Contributor-plus team member for initial proposal review - @situchan (
External)48 remaining items
situchan commentedon Dec 1, 2025
BugZero Checklist:
[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: https://github.com/Expensify/App/pull/55508/files#r2575495270
[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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue:
Regression Test Proposal
Already exists https://test-management.browserstack.com/projects/2219752/test-runs/TR-1392/folder/13177080/41237957/964488860
zanyrenney commentedon Dec 4, 2025
https://www.upwork.com/jobs/~021981775013425327474 - please can you apply to the job @samranahm
samranahm commentedon Dec 4, 2025
Thank you @zanyrenney, I've applied for the job.
zanyrenney commentedon Dec 4, 2025
offer sent @samranahm
zanyrenney commentedon Dec 4, 2025
@situchan can you also apply please?
situchan commentedon Dec 4, 2025
@zanyrenney can you please unassign and assign me back?
melvin-bot commentedon Dec 4, 2025
❌ There was an error making the offer to @situchan for the Contributor role. The BZ member will need to manually hire the contributor.
situchan commentedon Dec 4, 2025
Hmm, it didn't work. ok, I will apply
Edit: applied
zanyrenney commentedon Dec 4, 2025
payment summary
@situchan requires payment (Needs manual offer from BZ) - paid $250 on upwork.
@samranahm requires payment (Needs manual offer from BZ) paid $250 on upwork.