Error with joins between progressive collections #811
Send to my agent- I've validated the bug against the latest version of DB packages
Describe the bug
If a LiveQuery uses a join with a collection that uses progressive syncMode this error happens (I tested using electric collections)
Uncaught (in promise) Error: Snapshot requests are not supported in full mode, as the consumer is guaranteed to observe all data
at ShapeStream.<anonymous> (index.mjs:966:15)
at Generator.next (<anonymous>)
at index.mjs:65:61
at new Promise (<anonymous>)
at __async (index.mjs:49:10)
at ShapeStream.requestSnapshot (index.mjs:964:12)
at DeduplicatedLoadSubset.loadSubset [as _loadSubset] (electric.js:312:24)
at DeduplicatedLoadSubset.loadSubset [as syncLoadSubsetFn] (subset-dedupe.js:41:34)
at CollectionSyncManager.loadSubset (sync.js:203:27)
at CollectionSubscription.requestSnapshot (subscription.js:113:46)
Also switching the syncMode to on-demand fixes the error (I think it loads all the joined collections cause I do not see any subset param sent in the request).
To Reproduce
Just a useLiveQuery with a join between collections with syncMode: progressive
/reproduce
Investigation Summary#
I investigated this issue and created comprehensive tests to reproduce the scenarios described. Here's what I found:
Analysis#
The error "Snapshot requests are not supported in full mode" occurs when
requestSnapshot()is called on a ShapeStream that's in full mode. For progressive mode collections:- During the buffering phase: uses
fetchSnapshot()✓ - After initial sync completes: returns early without calling
requestSnapshot()✓
Looking at the timeline:
- This issue was created on Nov 13, 2025
- PR #852 "fix electric collection progressive mode" was merged on Nov 21, 2025
- PR #852 specifically fixed progressive mode to use
fetchSnapshot()during buffering and avoidrequestSnapshot()entirely after initial sync
Test Results#
I created tests covering:
- Joins between two progressive collections after initial sync
- Joins when the joined collection is still in buffering phase
- Ordered queries on progressive collections (from the comment by @am1006)
- Ordered queries with limit
All tests pass, confirming the current code handles these scenarios correctly without calling
requestSnapshot().Conclusion#
This issue appears to have been already fixed by PR #852 (released in v0.2.4, current version is v0.2.31).
If you're still experiencing this issue, please verify you're using
@tanstack/electric-db-collectionversion 0.2.4 or later. If you can still reproduce with the latest version, please provide:- Exact package versions
- Minimal reproduction code
- Full error stack trace
PR#
I've submitted #1232 which adds regression tests to ensure this scenario stays covered.
- During the buffering phase: uses
Closing this issue as it appears to be solved.
kevin-dp(GitHub profile, opens in a new tab) closed this
Sign in to join this conversation.
I've also observed this behaviour when using
useLiveSuspenseQuery: