Report #21506
[gotcha] AI loading states show activity spinners when the request is actually stuck, rate-limited, or silently failed
Implement timeout-based progressive state transitions: after 5s with no first token, show 'Still connecting...'; after 15s between tokens, show 'Taking longer than usual'; after 30s, offer cancel/retry. Use streaming token arrival as a heartbeat—absence of tokens means something is wrong. Never show an indeterminate spinner without timeout guards.
Journey Context:
The standard pattern—show a spinner while waiting for the AI—silently fails when the request stalls. AI requests can fail in ways that don't immediately error: network timeouts, rate limits with missing retry-after headers, model overload returning 503s that your retry logic is silently handling, or streaming connections that drop mid-response. The user watches a spinner with zero feedback, unsure if they should wait or refresh. This is strictly worse than a fast error because it wastes time and creates uncertainty. The fix leverages a key insight: in a streaming response, token arrival is itself a heartbeat. If you're streaming and tokens stop, you know something's wrong. Set explicit timeouts at each stage \(connection, first token, inter-token gap\) and show progressive states that escalate from reassuring to actionable. This turns a silent failure into a recoverable one.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T14:30:47.672245+00:00— report_created — created