Skip to content

fix(web): suppress load-error UI during session expiry - #2738

Merged
cursor[bot] merged 2 commits into
mainfrom
cursor/dedupe-session-load-errors-80d0
Aug 10, 2026
Merged

fix(web): suppress load-error UI during session expiry#2738
cursor[bot] merged 2 commits into
mainfrom
cursor/dedupe-session-load-errors-80d0

Conversation

@tyler-dane

@tyler-dane tyler-dane commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Summary

When a session expires, the API interceptor already signs the user out and shows the global You've been signed out toast. Event/calendar queries still landed in isError, so the UI also showed Couldn't load… + Retry — two conflicting CTAs.

Session recovery now owns that story: contextual load-error UI only appears for non-session failures. CalendarList stays quiet on 401/410 instead of inventing an empty-list message.

Simplicity

Shared shouldShowContextualLoadError / isSessionLevelError helpers; callers stay thin. Review follow-up removed a weak presentational EventGrid test that did not exercise Day/Week wiring.

Automated validation

  • Focused web unit tests for api.util helpers, event.util mutation suppress path, EventGrid, CalendarList (401 quiet + ordinary Retry).
  • No live browser session-expiry scenario: requires SuperTokens/auth cookies not provisioned in this environment (AGENTS.md login rule). Covered by interceptor + UI unit tests instead.

Independent review

Fresh diff-first review: ship-with-nits. Confirmed important finding fixed — CalendarList no longer falls through to “Connect Google…” / “No calendars yet.” after session-level load failure. Residual: Day/Week session suppress is util-tested but not integration-tested; pre-existing 410 toast copy differs from 401.

Test plan

  • bun test:web on api.util.test.ts, event.util.test.ts, EventGrid.test.tsx, CalendarList.test.tsx — pass
  • bun lint — pass for this change
  • CI on PR (lint, type-check, unit, e2e, CodeQL) — pass
Open in Web Open in Cursor 

cursoragent and others added 2 commits August 10, 2026 19:31
Session recovery already shows the signed-out toast; hide redundant
Couldn't load events/calendars Retry overlays for the same 401/410.

Co-authored-by: Tyler Dane <tyler-dane@users.noreply.github.com>
Hide the false empty-list copy when calendars fail for 401/410, so
session recovery remains the only story.

Co-authored-by: Tyler Dane <tyler-dane@users.noreply.github.com>
@tyler-dane
tyler-dane marked this pull request as ready for review August 10, 2026 19:44
@cursor
cursor Bot merged commit 2d021fd into main Aug 10, 2026
20 checks passed
@cursor
cursor Bot deleted the cursor/dedupe-session-load-errors-80d0 branch August 10, 2026 19:44
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