fix: defer SSO backend switch until confirmation sheet fully dismisses to avoid presentation race - WPB-28698 🍒 - #5236
Merged
Conversation
…s to avoid presentation race - WPB-28698 (#5235) Co-authored-by: Sam Wyndham <samwyndham@users.noreply.github.com>
jullianm
approved these changes
Sep 16, 2026
zenkins
approved these changes
Sep 16, 2026
zenkins
left a comment
Collaborator
There was a problem hiding this comment.
✅ Auto-approved cherry-pick PR 🍒.
jullianm
enabled auto-merge
September 16, 2026 06:31
Contributor
Author
Test Results122 tests 122 ✅ 9s ⏱️ Results for commit ef0cf8a. Summary: workflow run #35064057473 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR was automatically cherry-picked based on the following PR:
Original PR description:
Issue
SSO login is stuck in infinite loading state after typing an email, the SSO authenticator modal don't show up.
OS error shows:
Attempted to present SFAuthenticationViewController from a view controller that is being dismissed: <_TtGC7SwiftUI29PresentationHostingControllerVS_7AnyView_: 0x11fb40700>Issue is self explanatory : we're trying to present a modal (Web authenticator) when another modal (Backend redirection) is being dismissed.
This issue started to occur with 4.26 prod release. No specific changes were introduced except these ones #4826 but this is not the root cause. I suspect these changes might have triggered a UI-related bug which is why we didn't experience that issue before (UI component remained unchanged in 4.26).
This PR fixes the UI issue by ensuring the presented (backend redirect) modal is fully dismissed before presenting the SSO modal.
Testing
Checklist
[WPB-XXX].UI accessibility checklist
If your PR includes UI changes, please utilize this checklist: