Repository navigation
Description
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Target branch: unstable
Observed behavior
An edit made less than ~2 seconds before reloading the channel editor stays in the browser's IndexedDB changesForSyncing table with no synced flag. After the reload the editor shows the edit, read from IndexedDB, but POST /api/sync/ never sends it.
syncChanges in serverSync.js sends only the revs in the in-memory changeRevs array, and nothing repopulates it on page load. Only forceServerSync, which publishing calls, sends every unsynced change.
Expected behavior
A change left unsynced by a reload reaches the server on the next sync after the page loads.
User-facing consequences
- Collaborators, other tabs and other devices never see the edit.
- The server copy stays stale until the author publishes.
Steps to reproduce
- Open a channel with an exercise and open the exercise's Questions tab in the edit modal.
- Click Edit on a question, type a word into the prompt and click Close.
- Within 2 seconds, reload the page.
- Wait 20 seconds, then open
/api/assessmentitem?contentnode=<exercise node id>:raw_datalacks the typed word. - In DevTools > Application > IndexedDB >
KolibriStudio>changesForSyncing, the change is still there, unsynced.
Context
- Alert to unsynced changes and ensure sync before closing the tab #4100 (closed, fixed in Display sync changes in channel edit toolbar #4126) flushes the debounced sync before unload; a reload inside the debounce window still leaves the change unsynced, and nothing sends it afterwards.
- Reproduced on the Show changes made elsewhere in an open exercise's questions #6484 branch at c880aca (Chromium 159, local dev server);
serverSync.jsis identical onunstable.
Acceptance Criteria
- After the steps above, the server's
raw_datacontains the typed word within one sync interval of the reload, without publishing. - A Jest test covers a change present in
changesForSyncingbut not inchangeRevsbeing sent by the next sync.
AI usage
Claude Code found this during automated browser QA of #6484, traced it to serverSync.js and drafted this issue.

Activity