Skip to content

Scope cloud-save status cache to the current sign-in - #405

Open
thehobbit85 wants to merge 2 commits into
elripalda:mainfrom
thehobbit85:codex/fix-cloud-save-peek-account
Open

thehobbit85 wants to merge 2 commits into
elripalda:mainfrom
thehobbit85:codex/fix-cloud-save-peek-account

Conversation

@thehobbit85

Copy link
Copy Markdown
Contributor

The newer-cloud-save badge cached results by game and local synced hash for five minutes. Switching accounts with the same local save could therefore reuse the previous account's list; a delayed list response could also repopulate the cache after switching.

Scope the cache to the data directory and current sign-in. Successful account changes invalidate cached lists and outstanding requests. Both the Saves tab and the badge admit results only for the sign-in that requested them. Refreshing the same account keeps valid cache hits, and accounts without a user ID remain supported through their token identity.

Synthetic filesystem regressions reproduce the account-switch and delayed-writer bugs before the fix. Controls cover same-account refresh, renewed tokens, sign-out, missing user IDs, failed account writes, separate data folders, sync changes and expiry. No real accounts or credentials are used. Save download/restore and HTTP authentication behavior are unchanged.

Validation: full Rust suite 963 passed / 1 ignored; full UI suite 661 passed / 11 platform skips; git diff --check clean. This is an additional correctness defect found while auditing the account/cloud-save reports.

@Xarishark Xarishark self-assigned this Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants