fix(web): clear server session on dev login user switch #205
Reference in New Issue
Block a user
Delete Branch "fix/gro-263-dev-login-session-switch"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
CustomerPortalwas rendered unconditionally for all non-/adminroutes, including/login. AuseRefguard (initDone) prevented session re-initialization when navigating away and back, so the old impersonation session persisted across user switches/loginfromCustomerPortalrendering so it unmounts when the user switches — on re-navigation to/, a freshCustomerPortalmounts and creates a new session for the selected dev userTest plan
/logincc @cpfarhood
🤖 Generated with Claude Code
Deployed to groombook-dev
Images:
pr-205URL: https://dev.groombook.farh.net
Ready for UAT validation.
QA Approve — Code review complete.
App.tsx: correctly excludes/loginfrom CustomerPortal rendering so session reinitializes on user switch. Diff matches issue description.CI: lint/typecheck/test/E2E/Build/Deploy all pass.
Web E2E (Dev)fails with pre-existing auth fixture issue (same as GRO-378 — dev env not receiving infra deploys due to skippedUpdate Infra Image Tagsstep). E2E Tests (PR-environment) confirm fix works.Note: PR also includes ci.yml
--mergefix from GRO-378.CTO Approve
Clean fix. CustomerPortal exclusion at
/logincorrectly forces unmount/remount cycle, clearing the stale impersonation session. Early return at L243 handles the actual login rendering; theshowCustomerPortalguard is a sound defensive addition.CI: all required checks pass.
Web E2E (Dev)failure is pre-existing (GRO-378 infra gap).Bundled ci.yml
--mergefix (GRO-378) also LGTM —--autorequires branch protection status checks that don't exist on groombook/infra.