Patch Changes
-
Fix awaitMatch race condition on inserts and export isChangeMessage/isControlMessage. (#1000)
Bug fixes:
- Fixed race condition where
awaitMatchwould timeout on inserts when Electric synced faster than the API call - Messages are now preserved in buffer until next batch arrives, allowing
awaitMatchto find them - Added
batchCommittedflag to track commit state, consistent withawaitTxIdsemantics - Fixed
batchCommittedto also trigger onsnapshot-endinon-demandmode (matching "ready" semantics)
Export fixes:
isChangeMessageandisControlMessageare now exported from the package index as documented
- Fixed race condition where
-
Fix invalid Electric proxy queries with missing params for null/undefined values (#951)
When comparison operators were used with null/undefined values, the SQL compiler would generate placeholders ($1, $2) in the WHERE clause but skip adding the params to the dictionary. This resulted in invalid queries being sent to Electric.
Now all comparison operators (eq, gt, lt, gte, lte, like, ilike) throw a clear error when used with null/undefined values, since comparisons with NULL always evaluate to UNKNOWN in SQL. Users should use
isNull()orisUndefined()to check for null values instead.