Skip to content

fix(auth): skip network retries during offline cold launch#1004

Merged
bmc08gt merged 1 commit into
code/cashfrom
fix/offline-cold-launch-delay
Jun 26, 2026
Merged

fix(auth): skip network retries during offline cold launch#1004
bmc08gt merged 1 commit into
code/cashfrom
fix/offline-cold-launch-delay

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Check connectivity before retrying getUserFlags(), updateUserProfile(), and savePrefs() in login(). When offline during a soft login (app restart), flags resolve to null immediately and the existing local fallback sets AuthState.Ready from cached DataStore — eliminating the ~6s spinner caused by 3 failed retries with 2s delays. Interactive logins still always attempt the network fetch. Data refreshes on reconnect via RealSessionController.

Check connectivity before retrying getUserFlags(), updateUserProfile(),
and savePrefs() in login(). When offline during a soft login (app
restart), flags resolve to null immediately and the existing local
fallback sets AuthState.Ready from cached DataStore — eliminating the
~6s spinner caused by 3 failed retries with 2s delays. Interactive
logins still always attempt the network fetch. Data refreshes on
reconnect via RealSessionController.

Signed-off-by: Brandon McAnsh <[email protected]>
@bmc08gt bmc08gt self-assigned this Jun 26, 2026
@github-actions github-actions Bot added type: fix Bug fix area: auth Login, session, access keys, identity labels Jun 26, 2026
@bmc08gt bmc08gt merged commit 0b303e9 into code/cash Jun 26, 2026
2 of 3 checks passed
@bmc08gt bmc08gt deleted the fix/offline-cold-launch-delay branch June 26, 2026 20:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: auth Login, session, access keys, identity type: fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant