TypeScript: pushAll writes onto the store instead of replacing it (ts-flush-replaces-store) #136
Loading…
Reference in a new issue
No description provided.
Delete branch "libby/ts-flush-merges-onto-store"
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?
Closes follow-up
cultlib-gaps:follow_up:ts-flush-replaces-store.SingleFileMessagePackBackingStore.pushAllreplaced the whole file with the entries given, soCultMesh.flush()from a node created withpullOnStart: false(or with a stale image) left the store without the records it never read. It now reads the store under the lock and writes the entries onto it aspushdoes: same-key records replaced, nothing else removed, retype refused byrequireOneTypePerKeyagainst the held records. Soft flush and the dangling-link case are unchanged. Same contract as Rustpush_all(#135) and C#/Python.Tests: store-level (replace by key, keep the rest, empty flush wipes nothing, retype refused byte for byte) and the reported scenario through
CultMesh.startNode(..., {pullOnStart:false}).flush()(fails before). Three existing tests that usedpushAllto reset a file now remove it first or expect the merge. cultcache-ts suite 93/93 with Rust, C#, Python interop; cultmesh-ts cultmesh.test 77/77.🤖 Generated with Claude Code