From 36ffffb89b1dfeca0163b6ecd9c46239aca6465e Mon Sep 17 00:00:00 2001 From: tv Date: Sat, 31 Oct 2026 13:27:22 +0100 Subject: sync messages are bytes outside the session SyncPayload is now an opaque byte container in transport. SyncSession::generate returns the encoded payload, state::decode_sync(&payload) decodes it off the document lock (as before), and receive takes the decoded message, which is a type only the session can open. transport/mod.rs no longer imports Automerge. --- src/state/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/state/mod.rs') diff --git a/src/state/mod.rs b/src/state/mod.rs index cf64dc3..673bd56 100644 --- a/src/state/mod.rs +++ b/src/state/mod.rs @@ -26,7 +26,7 @@ mod timing; pub(crate) use peer::{HelloState, Incidents, Keepalive, Liveness, PeerState, Standing}; pub(crate) use read::{ReadSource, StaleView}; -pub(crate) use session::SyncSession; +pub(crate) use session::{SyncSession, decode as decode_sync}; pub(crate) use timing::Timing; use std::collections::HashMap; -- cgit v1.3.1