fix(desktop-windows): reset onboarding when a different account signs in - #7
Open
formed2forge wants to merge 2 commits into
Open
fix(desktop-windows): reset onboarding when a different account signs in#7formed2forge wants to merge 2 commits into
formed2forge wants to merge 2 commits into
Conversation
reconcileAccountForSignIn detected a UID change and wiped user data, but onboardingCompletedAt survived teardown — so a second user on the same machine was dropped straight into the home screen without seeing the setup wizard. Fix: call resetOnboarding() (deletes onboardingCompletedAt + onboardingStep) just before teardownUserData() inside the stored!==uid branch of reconcileAccountForSignIn. Same-user re-auth and first-ever sign-in are unaffected (guard condition unchanged). Verified: pnpm test -- authTeardown.test.ts passes (7 tests, 3 assertions updated to pin resetOnboarding call-count per branch). Failure-Class: none Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KADKRuaPJdho9CDE7nLXQP
formed2forge
force-pushed
the
fix/windows-onboarding-per-account-reset
branch
from
August 26, 2026 13:34
d4a939a to
bc6d5d3
Compare
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.
Summary
reconcileAccountForSignIndetected a UID change and wiped user data, butonboardingCompletedAtsurvived teardown — so a second user on the same machine was dropped straight into the home screen without seeing the setup wizard.Fix: call
resetOnboarding()(deletesonboardingCompletedAt+onboardingStep) just beforeteardownUserData()inside thestored !== uidbranch. Same-user re-auth and first-ever sign-in are unaffected.Test plan
pnpm test -- authTeardown.test.tspasses (7 tests)🤖 Generated with Claude Code