From 52e40764cf4441dfb507efeef5f32644eae94993 Mon Sep 17 00:00:00 2001 From: tv Date: Fri, 13 Nov 2026 03:25:50 +0000 Subject: screen: refuse what Automerge's transactions never write Automerge 0.12.0 takes some changes that name nothing wrong, and then can't give them back: a deletion that replaces nothing, a value put at a list's head without being inserted, a mark ended where no mark began right before it. Giving the change back panics, the save doesn't load, and a sync to a peer that lacks it panics: one member stops every node it reaches. Those are refused with the other checks (`changes::Written`). --- docs/access.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/access.md b/docs/access.md index dd87d3c..976197e 100644 --- a/docs/access.md +++ b/docs/access.md @@ -314,8 +314,10 @@ wouldn't have written: bytes that aren't Automerge's encoding of the change; a f operation not numbered one after the highest of its dependencies; a change that isn't its actor's first and doesn't build on the one before; an operation naming one that wasn't made in the change's own history, or that isn't what it is named as (the -object written into, the element of that list, a value replaced at that place). -Automerge applies some of those, and then panics, saves a document that doesn't +object written into, the element of that list, a value replaced at that place); and +anything Automerge's own transactions never write (a deletion replacing nothing, a +value put at a list's head without being inserted, a mark ended but right after its +begin). Automerge applies some of those, and then panics, saves a document that doesn't load, or holds another change than the one it was given. All of it is asked of the change and its history alone, so two nodes that hold a change's history come to the same, whatever else they hold: a change of the same batch refused after it passed -- cgit v1.3.1