Offline capture rejected by the server retries forever with no user-visible reason #108
Labels
No labels
bug
duplicate
enhancement
future
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/TeaLeaves#108
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Severity: Medium · Confidence: High · Effort: S · Category: ui
Evidence
app/src/hooks/useOfflineQueue.ts:83-104-sync(): onres.ok === false(e.g. 400 validation or 401 after session expiry) the item is neither removed nor flagged; thecatchonlybreaks for thrown/network errors.app/src/components/layout/QuickCapture.tsx:406-411- only a generic "N offline captures pending" banner.Problem
A queued offline capture rejected by the server (content too long, session expired) is retried on every
sync()(each 'online' event) indefinitely, with no error state exposed - the pending banner never resolves and never explains why.Impact
A permanently stuck capture the user can neither see the reason for nor clear. Data limbo.
Fix
On
!res.ok, capture the response and surface a per-item "failed to sync - " state, with a way to view/discard/edit the stuck item.Acceptance criteria
Filed from the 2026-07-15 codebase audit. Full report:
docs/.internal/report-2026-07-15.md(gitignored).A server-rejected offline capture (400/401) is now captured with its reason, flagged so auto-sync skips it (no more infinite silent retry), and surfaced in a panel with per-item Retry (e.g. after re-login) and Discard.
pendingCountexcludes flagged items so the banner can reach zero. Covered by new tests (no-auto-retry, retry, discard).Shipped in
59e4fdd(test fix6561f9a), part of the v7.3.0 milestone. Verified on dev (v7.2.1-3-g6561f9a): app suite 65/65 and api suite 268/268 green on the dev server; the one CI red was the known runner flake (iac#159), not this change.